So, I have a program I'm making in the process of taking my classes. I'll post my code below.
I don't need any programming tips or anything, I just need to know what the desired variable is. Right now, it says float, which will allow for numbers. What do I need to put to make it accept words? Thanks
Code:
import java.util.Scanner;
public class ROMBox {
ÂÂÂÂpublic static void main(String[] args) {
ÂÂÂÂÂÂÂÂScanner ROM = new Scanner (System.in);
ÂÂÂÂÂÂÂÂfloat Region, Title, Hack, Emulator;
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂSystem.out.println ("Hello. Welcome to ROMBox. Please wait while we fetch the necessary files.");
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂtry {Thread.sleep(4000);} catch(InterruptedException e) {}
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂSystem.out.println ("");
ÂÂÂÂÂÂÂÂSystem.out.println ("Loading...");
ÂÂÂÂÂÂÂÂSystem.out.println ("");
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂtry {Thread.sleep(2000);} catch(InterruptedException e) {}
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂSystem.out.print ("Please Enter the Desired Region: ");
ÂÂÂÂÂÂÂÂRegion = ROM.nextFloat();
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂSystem.out.print ("Please Enter the Desired Title: ");
ÂÂÂÂÂÂÂÂTitle = ROM.nextFloat();
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂSystem.out.print ("Please Enter any Desired Hacks: ");
ÂÂÂÂÂÂÂÂHack = ROM.nextFloat();
ÂÂÂÂÂÂÂÂ
ÂÂÂÂÂÂÂÂSystem.out.print("Do You Have an Emulator Available? ");
ÂÂÂÂÂÂÂÂEmulator = ROM.nextFloat();
ÂÂÂÂ}
}
I don't need any programming tips or anything, I just need to know what the desired variable is. Right now, it says float, which will allow for numbers. What do I need to put to make it accept words? Thanks