Criterion
1. CustomerType enumeration contains constants representing 3 customer types: retail, trade and college
2. CustomerType contains getDiscount method that returns the appropriate discount for each customer type: 10% for retail, 30% for trade and 20% for college
3. CustomerType enumeration contains a toString method returning an appropriate string for each customer type: Retail customer, Trade customer and College customer
4. Contains CustomerTypeApp class that compiles correctly
5. CustomerTypeApp main method declares a CustomerType variable
6. CustomerTypeApp main method assigns valid customer type to its CustomerType variable
7. CustomerTypeApp main method displays the discount for its CustomerType variable
8. CustomerTypeApp main method displays the string for its CustomerType variable
public class CustomerTypeApp
{
public static void main(String[] args)
{
// display a welcome message
System.out.println("Welcome to the Customer Type Test applicationn");
// get and display the discount percent for a customer type
// display the value of the toString method of a customer type
}
// a method that accepts a CustomerType enumeration
}