Java Keyboard Reader: V1.3 to Newest Version

  • Java
  • Thread starter thharrimw
  • Start date
  • Tags
    Java
In summary, the conversation is about a person struggling to get the keyboard reader to work while teaching themselves Java. They are using a book from 2004 and are not sure if the syntax is outdated. Another person offers to help and asks for more information about the issue. They also mention that the KeyboardReader is not a standard part of Java and needs to be included in the program.
  • #1
thharrimw
115
0
I have recently started to try to teach myself java and i can't get the keybord reader to work.
I'm a book thet's for java V1.3 but I'm using the newest version is that the problem? unless the book was wong then my program syntax should be fine. could anyone tell me what the syntax for the keybord reader is?
 
Technology news on Phys.org
  • #2
BufferedReader in
= new BufferedReader(new InputStreamReader(System.in));

I believe this is what you need. Are you planning to run your program using the cmd or gui?
 
  • #3
cmd it's just a basic temp. converting program. I'm not used to jave I've only programmed on my ti 83+, 89T, and Nspier
 
  • #4
if i copy and past my program could you show me what's wrong? the book that i have is fron 2004 so i don't know if it's syntax is out of date or not.
 
  • #5
Sure...you could copy and paste it here. I take a look at it. See what's up.

FYI: I'm a intermediate java and c++ programmer.
 
  • #6
ImputTerminalIO.KeyboardReader
public class converter {
public static void main(String [] args) {
KeyboardReader reader = new KeyboardReader();
double f;
double c;

System.out.print("enter F: ");
f =reader.readDouble();

c = (f-32.0)*5.0/9.0;

System.out.println("The equivalent in c is ");

reader.pause();
}
}
 
  • #7
that's exactly as it was in my java book.
 
  • #8
You need to tell us EXACTLY what's happening -- what error messages you're seeing, etc. -- not just "I can't get it to work."

The "KeyboardReader" is not a standard part of the Java programming language. If the KeyboardReader was provided in your book, you need to also type that into a file called "KeyboardReader.java" and compile it along with your own program.

- Warren
 

FAQ: Java Keyboard Reader: V1.3 to Newest Version

1. What is Java Keyboard Reader and what does it do?

Java Keyboard Reader is a program that allows users to read keyboard input in Java applications. It is designed to make keyboard input easier and more efficient for developers.

2. What are the new updates in V1.3 of Java Keyboard Reader?

Some of the new updates in V1.3 include improved compatibility with different operating systems, bug fixes, and new features such as customizable key bindings and multi-key shortcuts.

3. How do I install Java Keyboard Reader?

To install Java Keyboard Reader, you will need to download the latest version from the official website and then follow the installation instructions provided. Make sure you have the latest version of Java installed on your computer.

4. How can I use Java Keyboard Reader in my Java application?

To use Java Keyboard Reader in your Java application, you will need to import the necessary classes and then create an instance of the KeyboardReader class. You can then use the methods provided by the class to read keyboard input and perform actions based on the input.

5. Is Java Keyboard Reader free to use?

Yes, Java Keyboard Reader is completely free to use for both personal and commercial purposes. It is an open-source project, so you can also contribute to its development and improvement.

Similar threads

Replies
3
Views
15K
Replies
20
Views
3K
Replies
4
Views
19K
Replies
3
Views
17K
Replies
3
Views
1K
Replies
5
Views
2K
Replies
10
Views
3K
Back
Top