COSC-1336
Programming Fundamentals I
Programming Assignment 3
Revise Listing 3.8, Lottery.java, to generate a lottery of a three-digit integer. The program prompts the user to enter a three-digit integer and determines whether the user wins according to the following rules:
• If the user input matches the lottery number in the exact order, the award is $10,000.
• If all digits in the user input match all digits in the lottery number, the award is $3000.
• If one digit in the user input matches a digit in the lottery number, the award is $1000.
Your program’s output should look like the sample shown below. Green text represents information entered by the user. Black text is produced by the program.
Enter your lottery pick (three digits): 768
Lottery is 723
Match one digit: you win $1,000
Store the source code in a file named Lottery.java. For example, your instructor’s source code would be stored in a file named LotteryPeggyDoerschuk.java. In comments at the top of the source code file place the following:
For this short paper activity, you will learn about the three delays model, which explains…
Topic : Hospital adult medical surgical collaboration area a. Current Menu Analysis (5 points/5%) Analyze…
As a sales manager, you will use statistical methods to support actionable business decisions for Pastas R Us,…
Read the business intelligence articles: Getting to Know the World of Business Intelligence Business intelligence…
The behaviors of a population can put it at risk for specific health conditions. Studies…