Interviews3 answers
Why Java does not support Pointers?
3 Answers
because java is also (.) pointer is defined already to pointer use in class and object
Deepak SharmaPosted Sep 3, 2023, 2:47 PM EDT
A pointer is a variable which can hold the address of another variable or object. But, Java does not support pointer due to security reason, because if you get the address of any variable you could access it anywhere from the program without any restriction even variable is private.
Bhagyashri KadamPosted Apr 30, 2021, 9:35 AM EDT
It,s just because of security. By not providing pointers java effectively provides another level of abstraction.
Aman GuptaPosted Jul 16, 2020, 1:47 AM EDT

