0

does system.out.print work in this way ?

is it same as System.out.print class A // system { static B o=new B(); } class B //printstream { void display(String s) { System.out.print(s); } } class PrintK { public static void main(String a[]) { A.o.display("somnath"); } }

4th Jun 2017, 5:51 PM
Somnath Ghosh
Somnath Ghosh - avatar
1 Antwort
0
Looks about right. If you're really interested, you can see the Javadoc here: https://docs.oracle.com/javase/7/docs/api/java/lang/System.html
5th Jun 2017, 6:22 AM
Jason Runkle
Jason Runkle - avatar