This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Substitute for Cin in Java?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Substitute for Cin in Java??" Watch "Substitute for Cin in Java??" New topic
Author

Substitute for Cin in Java??

divyasheel sharma
Greenhorn

Joined: Feb 15, 2001
Posts: 19
Hi !
Like we have Cin in C++ (actually I dont know much C++ either)
Can anyone help me out , how we input values from keyboard in Java program say I need to make a program...
To read two numbers from keyboard and display the larger value on screen.
So I need in output... I can put various numbers and run the program.
Rgds
Divya
------------------
Eat Java,Drink Java...surf only Javaranch!


Eat Java,Drink Java...surf only Javaranch!
divyasheel sharma
Greenhorn

Joined: Feb 15, 2001
Posts: 19
HI Cindy!
Actually I just read the discussion on input from keyboard with Rashid, but I cud not get it , can u explain with the code for the program I have mentioned.
Thanx in advance.
Divya
------------------
Eat Java,Drink Java...surf only Javaranch!
Cindy Glass
"The Hood"
Sheriff

Joined: Sep 29, 2000
Posts: 8521
Try something like this:

[This message has been edited by Cindy Glass (edited February 19, 2001).]


"JavaRanch, where the deer and the Certified play" - David O'Meara
 
Consider Paul's rocket mass heater.
 
subject: Substitute for Cin in Java??
 
Similar Threads
Sending any string via cmd. code given
How to input something ?
Taking interactive input from console
reading binary file in java(with code also)
Input data