File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes reading integers from console into program Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic

reading integers from console into program

chintan chainani

Joined: Sep 21, 2005
Posts: 7

hye, i'm not quite able to figure this out, if someone can help by showing some example code :
i wanna enter integers into the variables from console after running program,am unable to do it with readInt(), also the input speciication is a space between integers. which are then taken as row and column of an int array.
am able to read it as char, but not as int. ??

p.s :pl reply ASAP, have been sitting on this too long.. thanks
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42965
Please do not post the same question to multiple forums: CarefullyChooseOneForum

Let's continue the discussion in this duplicate thread.
I agree. Here's the link:
subject: reading integers from console into program
It's not a secret anymore!