Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Task is to be done in thinkerCad Task 3.1: Create a new Arduino program that plays a game where it asks the user to guess

Task is to be done in thinkerCad

image text in transcribed

Task 3.1: Create a new Arduino program that plays a game where it asks the user to guess a number between 15 and 91, and tells them whether they are correct or if their next guess should be higher/lower. Here are the basic steps: 1. In setup(), seed the random number generator and generate a random number between 15 and 91 and store it in a global variable. 2. Ask the user to input a guess and then wait for them to enter their guess in the Serial Monitor. 3. Use an IF/ELSE IF/ELSE statement to determine if they guessed correctly, high, or low, and then output a descriptive message. If they were wrong, have them guess again (HINT: If you write your code right, (2) and (3) will be in the loop() function and you won't have to do anything special to make it ask again, other than let it finish loop and start over). Turn in a copy of your code and a (readable) screenshot of the Serial Monitor output for a game in which you had at least one number too high, one number too low, and the correct

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

Step: 3

blur-text-image

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 Systems An Application Oriented Approach Complete Version

Authors: Michael Kifer, Arthur Bernstein, Richard Lewis

2nd Edition

0321268458, 978-0321268457

Students also viewed these Databases questions