crispusbiegon / javax

uppercase conversion where i have a code but when i run it give me error
0 stars 0 forks source link

uppercase #1

Open crispusbiegon opened 7 years ago

crispusbiegon commented 7 years ago

i having an error running the code

crispusbiegon commented 7 years ago

import static java.lang.System.in; import static java.lang.System.out; import java.util.Scanner;

public class upperclasscnvt { public static void main(String[]args){ Scanner scan = new Scanner(System.in); System.out.print("Enter Input filename: "); String fileIn = scan.next(); System.out.println("Enter output filename: "); String fileOut = scan.next();

int buf = -1; while((buf = in.read())>-1) { char c = (char)buf; if (Character.isLetter(c)) { out.write(Character.toUpperCase(c)); } else { out.write(c); } } } }