Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 How to input a char in java?
Index -> Programming, Java -> Java Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
abogaida




PostPosted: Thu Apr 02, 2009 11:25 am   Post subject: How to input a char in java?

Hello,

i was wondering about the input of (Char) in java using the Scanner method?
Sponsor
Sponsor
Sponsor
sponsor
andrew.




PostPosted: Thu Apr 02, 2009 2:30 pm   Post subject: RE:How to input a char in java?

This should be in the Java section, but it's basically something like this:
- You create your scanner (Scanner sc = new Scanner (System.in); )
- Then you create your char and give it the value of the first character from the input (char ch = sc.nextLine().charAt(0); )
abogaida




PostPosted: Thu Apr 02, 2009 4:17 pm   Post subject: RE:How to input a char in java?

I'm sorry but I tried to write in the java section but its telling me that the addition of a new post is limited to certain users.
Display posts from previous:   
   Index -> Programming, Java -> Java Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 3 Posts ]
Jump to:   


Style:  
Search: