For this project you are tasked with building a user application that will select sets of...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
For this project you are tasked with building a user application that will select sets of random numbers. Your application must use functions and pass values. Your program will pick sets of 6 random numbers with values of 1 to 53. The user should be able to choose how many sets to produce. The challenge will be to ensure that no number in a set of 6 Is a repeat. Your program should prompt the user and ask them how many number sets they wish to have. This could be used as a lottery ticket quick pick application. For those who do not condone gambling, it could just be a tool to select random numbers for a game of fun. Objectives: ● ● . ● . Use of functions and passing by value. Use of repetition constructs (loops). The understanding and use of selection. The use of the random number generator and seeding. Display formatted output using input/output statements. Use format control strings to format text output. Minimum Requirements: Your program must make use of the following. 1. Your program must compile on the Osprey server. -25 points if I have to fix it to compile. Make sure to watch the videos on how to copy files into osprey and how to verify them on osprey. 2. Your program must use a function to prompt the user for input and return it to the calling function. This function will determine the number of groups of 6 random numbers to generate. The function should also allow the user the opportunity to enter in a value to quit. Recall that a 'Q' has a value and a 'q' has a value. You may use a character or a special number value to determine the user has selected to quit and your program would indicate this to the calling function. Your function will not exit the program but return a value to the caller indicating the user wants to quit. 3. Your program must use a function to get and return random values to the calling function. This function should take as arguments a value for the range and the offset. This makes the function reusable for other random number needs. The function. should return the random integer value to the calling function. -20 max for no function or no usable function, -15 for no range control, -10 for no parameters being used. 4. The range and offset to be used in your program must use a defined constant and The range should be inclusive values 1 thn 53. For this project you are tasked with building a user application that will select sets of random numbers. Your application must use functions and pass values. Your program will pick sets of 6 random numbers with values of 1 to 53. The user should be able to choose how many sets to produce. The challenge will be to ensure that no number in a set of 6 Is a repeat. Your program should prompt the user and ask them how many number sets they wish to have. This could be used as a lottery ticket quick pick application. For those who do not condone gambling, it could just be a tool to select random numbers for a game of fun. Objectives: ● ● . ● . Use of functions and passing by value. Use of repetition constructs (loops). The understanding and use of selection. The use of the random number generator and seeding. Display formatted output using input/output statements. Use format control strings to format text output. Minimum Requirements: Your program must make use of the following. 1. Your program must compile on the Osprey server. -25 points if I have to fix it to compile. Make sure to watch the videos on how to copy files into osprey and how to verify them on osprey. 2. Your program must use a function to prompt the user for input and return it to the calling function. This function will determine the number of groups of 6 random numbers to generate. The function should also allow the user the opportunity to enter in a value to quit. Recall that a 'Q' has a value and a 'q' has a value. You may use a character or a special number value to determine the user has selected to quit and your program would indicate this to the calling function. Your function will not exit the program but return a value to the caller indicating the user wants to quit. 3. Your program must use a function to get and return random values to the calling function. This function should take as arguments a value for the range and the offset. This makes the function reusable for other random number needs. The function. should return the random integer value to the calling function. -20 max for no function or no usable function, -15 for no range control, -10 for no parameters being used. 4. The range and offset to be used in your program must use a defined constant and The range should be inclusive values 1 thn 53.
Expert Answer:
Answer rating: 100% (QA)
Program CODE include include include define RANGE 53 define OFFSET 1 ... View the full answer
Related Book For
Introduction to Emergency Management
ISBN: 978-0471772606
1st edition
Authors: Michael K. Lindell, Carla Prater, Ronald W. Perry
Posted Date:
Students also viewed these chemical engineering questions
-
You were asked to calculate the convexity of a 10 year bond that has a coupon of 2.80% and a YTM of 3.40%. You could have typed the numbers into the duration calculator rather than actually...
-
.. As a financial analyst, you are tasked with evaluating a capital-budgeting project. You were instructed to use the IRR method, and you need to determine an appropriate hurdle rate. The risk-free...
-
Choose an Australian industry and analyse the most important factors affecting its profitability by using the relevant concepts and theories we have studied in Lectures 1-9. You should choose the...
-
Which of the following statements is true for real gases? Choose all that apply. 1. As attractive forces between molecules increase, deviations from ideal behavior become more apparent at relatively...
-
Suppose that (2f is identically zero in a region S. Show that? as = || IV/P |Vfl dV f Df dS as
-
Does RPB actually create a shortest path tree? Explain. What are the leaves of the tree?
-
Assume the same data as given in problem 9, except the company expects the following production: Case A: 300 bbl per month Case B: 500 bbl per month REQUIRED: a. Determine the number of months needed...
-
Fenton Company applied FIFO to its inventory and got the following results for its ending inventory . Cameras 100 units at a cost per unit of ....... $68 DVD players 150 units at a cost per unit of...
-
A. Let the number be presented by the variable "x". Translate the following mathematical phrases/sentences to mathematical symbol. Statement 1. The product of a number and seven is equal to two more...
-
In the investment world, commodities are typically pretty boring. From livestock to grains to steel and other metals, commodities have their ups and downs. But long term, the world will always need...
-
Weather forecasters know they are making future predictions based only on past and present observations. What if a colleague told you that an investment in that new startup was a sure thing?
-
Why the USALI is better for lodging companies than normal accounting systems that other companies use?
-
5. What information should be considered when evaluating the replacement of an old asset by a new asset?
-
What is an account payable? What transactions result in the recognition of an account payable?
-
What value should the variable y be so that the variable x becomes the integer 20? x = 10 if x 19: x = 2 if x > y: x = 2
-
This project has two purposes: first to make you familiarize with sockets/RPCS/RMIs, processes, threads; second to learn the design and internals of a peer-to-peer (P2P) file sharing system. You can...
-
What class of laws did local governments pass to empower police departments to regulate groups' right to be in public life?
-
Beginning with a country that has a trade deficit, demonstrate graphically what will happen to a countrys potential output with globalization if that countrys costs of production fall. Explain your...
-
Define capability assessment and capability shortfall.
-
Name the main types of federal government programs that provide recovery assistance.
-
Define human vulnerability.
-
The purpose of site-directed mutagenesis and CRISPR-Cas technology is to a. determine if a protein binds to a DNA segment. b. determine the sequence of a segment of DNA. c. alter the sequence of a...
-
In one PCR cycle, the correct order of steps is a. primer annealing, primer extension, denaturation. b. primer annealing, denaturation, primer extension. c. denaturation, primer annealing, primer...
-
During Western blotting, the primary antibody recognizes a. the secondary antibody. b. the protein of interest. c. an mRNA of interest. d. a specific fragment of chromosomal DNA.
Study smarter with the SolutionInn App