Check if a file existsTag(s): IO


import java.io.*;

public class FileTest {
  public static void main(String args[]) {
    File f = new File(args[0]);
    System.out.println
      (f + (f.exists()? " is found " : " is missing "));
  }
}

blog comments powered by Disqus