What is a pointer and does Java support pointers?

1 votes
210 views
Aniruddh Singh asked 20-Dec-2017 in Technology by Aniruddh Singh

What is a pointer and does Java support pointers?

1 Answer

0 votes
Harsh kumar srivastava answered 20-Dec-2017 by Harsh kumar srivastava

The Pointer is an object, whose value points to or refers to another value stored elsewhere in the computer memory using its memory address.

Or in other words, we can say that pointer is programming object which handles the reference of another variable value stored in the memory.

No, Java doesn't support Pointer, While we use the pointer in memory, improper handling of pointers leads to memory leaks and reliability issue hence java doesn't support the usage of Pointers.


Hope it's informative for you...