How variables are declared?



How variables are declared?..

Answer / Ravi Soni

In Java, variables can be declared using the 'dataType variableName;' syntax. For example, int x; for an integer variable.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

Can an unreferenced object be referenced again?

1 Answers  


I have an HashMap object, which has with key and value pair. It has 10 keys and values in that object. Now the question is I want insert new key and value in middle or any where in that list but not at the end or at the top. Is it possible or not. If yes how can we achieve this one?

2 Answers   Huawei,


What is remote method invocation (rmi)?

1 Answers  


how can you say that java is independ language

2 Answers   TCS, Wipro,


Why spring singleton is not thread safe?

1 Answers  


Name few java 8 annotations ?

1 Answers  


Why do we need wrapper class?

1 Answers  


what is synchronization and why is it important? : Java thread

1 Answers  


What is class level lock ?

1 Answers  


How can we pass argument to a function by reference instead of pass by value?

1 Answers  


How do you compare two strings lexicographically?

1 Answers  


What are pass by reference and pass by value?

1 Answers  


Categories