public class Prog0
{
//prep for first part of Assignment #3
    static ConsoleReader kbd;

	public static String question()
	{
		String s, ans;
		boolean valid;
		do
		{
			System.out.println("Continue? (Y/N)");
			s = kbd.readLine();
			ans = s.toUpperCase();
			valid = ans.equals("Y") || ans.equals("N");
			if(!valid)
			{
				System.out.println(ans + " not a valid response. Retype");
			}			
		}while (!valid);
		return ans;
	}
	public static void main(String[] asd)
	{	
	    kbd = new ConsoleReader();
		String ans = "Y";
		Dice player = new Dice(100, "Razia");
		System.out.println(player.getName() );
		while( !player.busted() && ans.equals ("Y" ) )
		{
			player.begin();
			if(!player.busted() )
			{
				ans = question();
			}
		}	
				
	}
}

class Dice
{
	private int amount;
	private String name;//instace variables (I.V.)
	
	public Dice(int amount, String name)
	{
		this.name = name;//this refers to instance variables
		this.amount = amount;
	}
	
	public String getName()
	{
		return name;
	}
	
	public boolean busted()
	{
		return amount == 0;
	}
	
	public void begin()
	{
	}		
}
		

