How to printf line in java
Hello I'm new in java and I have an assignment to printf a line. I think it is printf line
in java but I'm only familiar with assembly and C++ advanced editions. How should I go about prin开发者_Python百科ting a line in Java??
System.out.printf(...) Javadoc
public class Main {
public static void main(String[] args) {
int i = 42;
System.out.printf("life universe and everything = %d%n", i);
}
}
精彩评论