Why cant we define System.out.println() inside a class
directly?

Answer Posted / shahid

because println method is not abstract method it is method
of output stream class so we cant override.and it is just
overloded method.

Is This Answer Correct ?    3 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is java life cycle?

780


How many bytes is double?

768


What do you understand by the term polymorphism?

848


What is the collection interface?

831


Whats the difference between notify() and notifyall()?

814


Where are the local variables stored?

802


Does constructor creates the object ?

820


What is garbage collector?

837


Define how destructors are defined in java?

797


Which of the following classes will have more memory allocated?

809


What is bufferedwriter?

761


What is java command?

815


Write a program to print all permutations of string?

924


What is not thread safe?

776


What is definition and declaration?

755