M
Q. Identify the incorrect statement?
Java is not a dynamically typed language; it is a statically typed language. This means that variable types are checked at compile-time, not at runtime. Static Typing in Java When you declare a variable in Java, you must specify its type explicitly. Once assigned, the type cannot change. Example: int num = 10; // 'num' is explicitly declared as an integer num = "Hello"; // ❌ Compile-time error: incompatible types This strict type-checking helps catch errors early, making Java a strongly typed and statically typed language.
You must be Logged in to update hint/solution
Q. An ordinal() method of an ENUM returns _____.
Q. A SWITCH statement accepts ___ type of data as input.
Q. What are the parts of a SWITCH in java?
Q. A switch statement in Java accepts ___ as input data.
Q. Which operator is used for string concatenation in Java?
Q. What are the keywords used to implement a SWITCH case in Java language?
Q. Choose the correct way of initializing a multidimensional array below.
Discusssion
Login to discuss.