Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


explain System.out.println

Answers were Sorted based on User's Feedback



explain System.out.println..

Answer / rajashekhar p

exactly System.out.println();
Solution
System is a Predefined public final class in the
java.lang package.
and out is the static variable of type PrintStream.
and println() method is contain in PrintStream class..

Hence we can invoke this method through class name (i.e
System)
code like as follows........

final class System{
static PrintStream out;
}
class PrintStream{
println();
-----------
------------
}

Is This Answer Correct ?    1 Yes 0 No

explain System.out.println..

Answer / nivrutti

'system' is a public class which is final which can never
be extended..It does not extends object.
'out' is the static variable of the class PrintStream desclared in system class.
'println()' is the method of printStream class..
since 'out' is a static variable it can be called by using
the class name'system'
so 'Sstem.out.println()'

Is This Answer Correct ?    1 Yes 0 No

explain System.out.println..

Answer / ramu.gadde

System:It is the class Name which is available in java.lang
package.

out: is the static variable(public static final
java.io.PrintStream out)

Analysis of out variable:
So many people are conflict about this out,
a)Either it is object or variable.

Reason:In java there is no static object(means with static
keyword it is called variable only)

println:is a method which is available in
Java.io.PrintStream class)

the step is considered by java team like this

class System
{
public static final java.io.PrintStream out=new PrintStream();
------
}
So they called System.out.println()

I think u understand about this completely.

Is This Answer Correct ?    1 Yes 0 No

explain System.out.println..

Answer / shyam

It is quite simple to understand the question but to answer it we need to dig deeper in to java native code.

System is static class and cannot be instantiated
out is a reference variable defined in System
println() is the method used to print on standard output.
A <a href = "http://www.javastudychannel.com/forum/2114-What-out-System.out.println-Java.aspx">brief and nice explanation</a> is always welcome on this as we can learn much from this single line of statement itself!!

Is This Answer Correct ?    1 Yes 0 No

explain System.out.println..

Answer / ramanjaneyulu.b

-->System is a class name

-->out is an object of a class

-->println is the printstream

Is This Answer Correct ?    1 Yes 0 No

explain System.out.println..

Answer / avinash

in c print and in c++ cout and in java
system.out.println()

system is classand package and out is an object of the
class printstream println is method of the printstream
printing string on console

Is This Answer Correct ?    11 Yes 11 No

explain System.out.println..

Answer / uday

'system' is a public class which is final which can never
be extended..It itself extends object.
'out' is the static object of the class PrintStream.
'println()' is the method of printStream class..
since 'out' is a static object it can be called by using
the class name'system'
so 'Sstem.out.println()'

Is This Answer Correct ?    0 Yes 0 No

explain System.out.println..

Answer / ashwani

system has a final class which can never instantiated by
other class. it has a private constructor has private or
private constructor never call, it call by jvm.

out: out is field type of static printer writer.

println: has a method of printsteam .

Is This Answer Correct ?    0 Yes 0 No

explain System.out.println..

Answer / sachin

System.out.println();

System - System is class
Out - Is an object of output stream (PrintStream class)
which is static and defined in System class.
Println()- Method from PrintStream class which use to write
output

Is This Answer Correct ?    0 Yes 0 No

explain System.out.println..

Answer / ramu.gadde

System is the class name which is Available in
java.lang.System class

out is a static variable which is also available in
java.lang.System class

println is the method which is available in
java.io.PrintStream class

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

what is polymorphism with example?types of polymorphism?

15 Answers   HP, Sigma Solve,


What is the default initialized value of String type variable?

4 Answers  


Can abstract class have private constructor?

0 Answers  


Why is java so popular?

0 Answers  


if arraylist size is increased from initial size what is the size of arraylist...suppose initial is 100 , if i add 101 element what is the size...

10 Answers  


What will happen if we write code like: try{}catch(exception e)catch(IOException i)

6 Answers   CTS, TCS,


how can you catch multiple exceptions in java?

0 Answers   Cyient,


Which java ide is used the most?

0 Answers  


What does this () mean in constructor chaining concept?

0 Answers  


How java enabled high performance?

0 Answers  


Why can't you declare a class as protected?

0 Answers  


String is a immutable objects . it means that string does not change........... But it will be chang......... { String s="kapil"; String s1="raj"; String s=s1; then print(.......) The String has been changed .. how it is possible and why its called immutable objects

7 Answers  


Categories