Minggu, 18 April 2010

Java file2

import java.io.File;

class File2{

public static void main(String[] args) {
File file_cek;

file_cek = new File("Latihan.txt");

if(file_cek.exists()){

System.out.println("file Latihan.txt sudah ada");


}
else{

System.out.println ("file Latihan.txt belum ada");

}
}
}