I'm reading Sams Teach Yourself Java in 24 Hours and came across this code:
class NewRoot {
public static void main(String[] args) {
int number = 100;
if (args.length > 0) {
number = Integer.parseInt(args[0]);
}
System.out.println(“The square root of “
+ number
+ " is "
+ Math.sqrt(number));
}
}
But in order for the code to be compiled, the writer enters 169
in the Arguments field in the
Run>Set Project Configuration>Customize
menu (in NetBeans IDE).
So my question is: what's the purpose of the specific field? Does 169 means something or is it just a random number? It's a pity the writer doesn't say anything about it!