i know there threads this, issue different. either thread closed or thread has no comments on, figured i'd start new one.
for reference, using netbeans jdk8. have been having lot of errors , cannot run desired. not sure why is, figured if guys. i've heard great things these forums.
my source code (taken sams teach java in 24 hours, 7th edition):
public class changer { public static void main(string[] arguments) { if (arguments.length > 0) { system.out.println("the original value: " + arguments[0]); float num1 = new float(arguments[0]); float num2 = num1.floatvalue(); int num3 = (int)num2; system.out.println("the final value: " + num3); } } }
the output:
run: exception in thread "main" java.lang.runtimeexception: uncompilable source code - cannot find symbol symbol: variable arguments location: class com.java24hours.changer @ com.java24hours.changer.main(changer.java:5) java result: 1 build successful (total time: 1 second) any appreciated.
Comments
Post a Comment