+ 1
About print statement
How can we write anyname.out.println instead of system.out.println in java code, what package we have to use ?
2 Respuestas
0
Print is not a statement.
You don't need to import anything, you can simply make your own function:
public static void print(String msg) {
System.out.println(msg);
}
If you want to print other datatypes too, you can make the same function with different arguments:
public static void print(int msg) {
System.out.println(msg);
}
0
That's not my question,my question is
public static void main() {
abc.out.println( );
}
Without writing system.out.println in the code how we can execute the above code.
Airree