A question about Java's Scanner class...
Code:
import java.util.Scanner; Code:
rgonzale@kronos:~1012 !gcj |
I am not sure what you are doing with gcj, and what a.out is supposed to be. But for me the below works flawlessly (using your code):
Code:
user@host:~/Test$ javac ForgetfulMachine.java |
Interesting thank you.
gcj is the gcc plugin for compiling java. The a.out file is a pre-compiled binary. rgonzale@kronos:~1010 file a.out a.out: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, not stripped Yes it works like a charm with javac. Thanks a lot. |
As joe said, worked with your code. Using eclipse. Just added io.close(); to close the scanner resource
http://i58.tinypic.com/fyhidl.png Quote:
|
All times are GMT -5. The time now is 05:56 PM. |