Q. Which of the following is not a valid way to declare a long variable in Java?

  • (A) long x = 123L
  • (B) long y = 123
  • (C) long z = 123.0
  • (D) long w = 0x1L
πŸ’¬ Discuss
βœ… Correct Answer: (C) long z = 123.0
Explanation: The correct answer is Option C: long z = 123.0.
Explanation by: Pooja
The correct answer is Option C: long z = 123.0.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
114
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Pooja
Publisher
πŸ“ˆ
99%
Success Rate