Which of the following is not a feature of Java?

Java MCQ: Which of the following is not a feature of Java?

a) Platform-independent
b) Object-oriented
c) Pointers
d) Secure

Answer:

c) Pointers

Explanation:

Java is a platform-independent, object-oriented, and secure programming language, but it does not support pointers. Pointers are used in languages like C and C++ to directly access memory addresses, but Java omits this feature to avoid complexity and improve security.

By removing pointers, Java reduces the risk of memory-related errors and vulnerabilities, making it safer and easier to use. This is part of Java’s design philosophy to be a robust and secure language for developing applications.

Understanding the features and limitations of Java is important for effectively using the language and avoiding misconceptions or errors in your programs.

Reference links:

https://www.rameshfadatare.com/learn-java-programming/
https://www.javaguides.net/p/java-tutorial-learn-java-programming.html

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top