when i run my project in java. i keep getting this stuff.
No Console ..... I dont know how to get console in eclipse.
here is my code.

import java.io.*;

public class WordGame {
	public WordGame()
	public static void main (String args[])
		String WordGuess;
		 WordJudge gm = new WordJudge();
		Console c = System.console();
		if (c == null){
			System.err.println("No Console.");
		while (!gm.gameEnded()){
			System.out.format("You have %d attempts remaining. \n", gm.getRemainingGuesses());
			strGuess = c.readLine("Enter your guess : ");
		if (gm.plyrwin()){
			System.out.format("You won ! It took you %d attempts. \n", gm.nGuessesNeeded());
			System.out.format("You lost. The word was %s \n", gm.GetTheWord());

please help me ... badly needed your reply ASAP. Tnx in advance guys.

Edited 5 Years Ago by ~s.o.s~: Added code tags, learn to use them.

Eclipse has its own environment, and you can't get at the ordinary console.
You can get the same capabilities using a BufferedReader with System.in

import java.io.BufferedReader;
  import java.io.IOException;
  import java.io.InputStreamReader;


          try {
             BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
             System.out.print("Type name: ");
             String name = reader.readLine();
             System.out.println("Hello " + name);
          } catch (IOException e) {
This question has already been answered. Start a new discussion instead.