Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

can you please write this code in .java perferably using netbeans. Also using import java.util.Random; and Random r = new Random(); int x = 1

image text in transcribed

can you please write this code in .java perferably using netbeans. Also using import "java.util.Random;" and "Random r = new Random(); int x = 1 + r.nextInt(10);" in the code please

Part 1: Picking those winning lottery numbers! Your mom loves playing the lottery each week, but she always takes forever to pick a set of numbers. It's driving you crazy because, who does she send to the store to get her lottery tickets? You! Wonderful child that you are, you've decided to help her by writing a program that will pick some numbers for her. Awesome! Think about how you can do this. Your mom likes to play both Fantasy 5 and the regular Lotto (6 numbers), so you want to write a program that takes this in account. o For Fantasy 5, the range of possible numbers should be from 1- 36 o For the Lotto, the range of possible numbers should be from 1- 53 Don't worry about whether you get duplicate numbers (we haven't learned enough about that yet) Assume that you will be given a method that gives you one random number. *Think about how you want to present her number picks to her. You'll want to be sure to great her and include some enthusiastic text along with her numbers (e.g. "Here are your winning numbers!") For Part 1, write an algorithm for your winning lottery number program, and then do several iterations of tests (i.e., step through your algorithm to make sure that it is logically correct and gives you the correct output). Put this in a Word or Open Office document. You'll turn that document in with the program that you create in Part 2

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Machine Performance Modeling Methodologies And Evaluation Strategies Lncs 257

Authors: Francesca Cesarini ,Silvio Salza

1st Edition

3540179429, 978-3540179429

More Books

Students also viewed these Databases questions

Question

10:16 AM Sun Jan 29 Answered: 1 week ago

Answered: 1 week ago

Question

2. Identify issues/causes for the apparent conflict.

Answered: 1 week ago