explain System.out.println()

Answers were Sorted based on User's Feedback



explain System.out.println()..

Answer / surya simhadri

System is a predefined class in lang package and out is a
static member with in a System class and also out is an
instance of PrintStream which is a static inner class of
System class and finally print() and println() are member
functions of PrintStream class. So we can call those
methods using out and out is called with class name in
which it is declared( bcoz it is static member variable of
system class). So finally we can call println as
System.out.println().
EX:
class System {
static public PrintStream out;
public static class PrintStream {
public string print(String s) {

}
public string println(String s) {

}
public static void main(String[] arg) {
System.out=new PrintStream();
System.out.println("");
}

}
}

Is This Answer Correct ?    20 Yes 1 No

explain System.out.println()..

Answer / esha prasad

As I remember, System is a class, out is a static
field/reference to an object of type Output stream and
println is the method of that o/p class.

Is This Answer Correct ?    14 Yes 1 No

explain System.out.println()..

Answer / harika

System is a predefined class,out is a reference of
printstream class,println is a method of printstream class.

Is This Answer Correct ?    8 Yes 0 No

explain System.out.println()..

Answer / ranabir chakraborty

System is a predefined final class.
out is a object of print stream class. and
println is a method.

Is This Answer Correct ?    7 Yes 3 No

explain System.out.println()..

Answer / purnachandra rao

printStream contains an object called obj and a class
called println();these total pllaced in system

Is This Answer Correct ?    2 Yes 0 No

explain System.out.println()..

Answer / sowjanya

System is the class name and out is the static variable of the System class.
Out is called a field in System Class.
Print() method is used to disply something on the monitor.

Is This Answer Correct ?    0 Yes 0 No

explain System.out.println()..

Answer / t.jaya govind sudhakar

in System.ou.println();
System is a predefined class in the java.lang package, and
out is a static field which reference to an object of type
Output stream and
println is the method of printstream class.

Is This Answer Correct ?    0 Yes 0 No

explain System.out.println()..

Answer / vetriselvan

this is a output commmand to print the result in java
programming.

Is This Answer Correct ?    6 Yes 7 No

explain System.out.println()..

Answer / vijay

System is a class,its a final class.out is a static object of PrintStream.println() is a method in PrintStream.We can,t directly call the Out object thats why we use System class


System.out.println()

Is This Answer Correct ?    1 Yes 2 No

explain System.out.println()..

Answer / debargha

System is a predefined final class;
out is a PrintStream object
and println is a built-in overloaded method in the out object.

Is This Answer Correct ?    2 Yes 3 No

Post New Answer

More Core Java Interview Questions

What is the difference between superclass and subclass?

0 Answers  


What are the differences between path and classpath variables?

0 Answers  


What is jagged array in java?

0 Answers  


What is diamond operator in java?

0 Answers  


Why Java is called as purely platform independent..? Explain briefly..dont Give regular answers Explain with your own example..?

8 Answers   Nokia,


Why do we need wrapper classes?

0 Answers  


what are the purposes of native, transiant key words?

2 Answers  


How many bytes is a url?

0 Answers  


What is a default constructor and also define copy contrucyor?

0 Answers   Global Logic,


suppose we have an interface & that interface contains five methods. if a class implements that interface then we have to bound that to give tha definition of all five methods in that class. If we declare that class as abstract then can we call only two methods to give the deinition of that method & i don't want to give the definition of all the methods? can it possible

6 Answers   HP, Wipro,


Is java an open source?

0 Answers  


What does system.gc() and runtime.gc() methods do?

0 Answers  


Categories