[3891] in java-interest

home help back first fref pref prev next nref lref last post

Can someone help me turn this code into Beta Version

daemon@ATHENA.MIT.EDU (Jonathan_Mark_Smith@CCMAIL.PRUSEC.)
Thu Nov 30 22:01:38 1995

From: Jonathan_Mark_Smith@CCMAIL.PRUSEC.COM
Date: Thu, 30 Nov 95 18:02:49 EST
To: java-interest@java.sun.com

     import java.io.*;
     class input {
             public static void main(String args[]){
                     System.out.println("Enter Directory:");
                     char ch;
                     StringBuffer dirBuf = new StringBuffer();
                     while((ch=(char)System.in.read()) != '\n')
                             dirBuf.appendChar(ch);
                     File dir = new File(dirBuf.toSting());
                     System.out.println("Enter FileName:");
                     StringBuffer fileBuf = new StingBuffer();
                     while((ch=(char)System.in.read()) != '\n')
                             fileBuf.appendChar(ch);
                     File input = new File(dir, fileBuf.toString());
                     if(input.exists()){
                             System.out.println("\nFile Found");
                             System.out.println("File Name:
                                "+input.getName());
                     } else {
                             System.out.println("File Not Found");
                     }
             }
     }

-
This message was sent to the java-interest mailing list
Info: send 'help' to java-interest-request@java.sun.com

home help back first fref pref prev next nref lref last post