UNB/ CS/ David Bremner/ teaching/ java/ SqrtTest1.java
public class SqrtTest1 
{  public static void main(String[] args)
   {  ConsoleReader console = new ConsoleReader(System.in);
      boolean done = false;
      while (!done)
      {  String inputLine = console.readLine();
         if (inputLine == null) done = true;
         else
         {  double x = Double.parseDouble(inputLine);
            double y = MathAlgs.sqrt(x);
            
            System.out.println("square root of " + x
               + " = " + y);
         }
      }
   }
}