Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

topic 02:00:00 P1_L1_guessColore upload is no 751-403 guess the color Submit P1_L1_guessColor B select the file SUM M guess color is a fun little game,

image text in transcribed

topic 02:00:00 P1_L1_guessColore upload is no 751-403 guess the color Submit P1_L1_guessColor B select the file SUM M guess color is a fun little game, here's a brief overview of some of its rules: : there are 6 colors of pins (each color of the pin can have more than one), the user needs to place a large needle in each of the 4 input slots in each round of the game, the user's input is fed back, the game ends 4 when the user's answer matches the correct answer the color of the pin in each slot matches the answer in that slot) or when the user still answers incorrectly after more than 8 rounds of the game. here are two types of feedback the color and position are correct the user input matches the answer to the corresponding location only the color is correct the user input does not meet the color and position are correct and of the answers in the other three locations that do not correspond to the user input at least one matches the user input. Here's a module you'll need to write in the Verileg language to provide feedback on the answers entered by the user in the game (regardless of whether the game is over or not). the module port is defined as follows: signal name direction description ! 1 the color number of the answer in the oth position ans0|2:01 ans12:01 1 the color number of the answer in the first position ans22:00 1 the color number of the answer in the second position ans3|2:01 1 the color number of the answer in the 3rd position input 2.0 1 the color number entered by the user at the oth position the color number entered by the user at the first position 1 input1 (2:0) input2[2:0) 2 input312:07 03 1 the color number entered by the user at the 2nd position 1 both_correct|2:0) OR the color number entered by the user at the 3rd position the number of inputs that are correct for both the user's color and position the number of enters that the user enters only the correct color color correct[2:01 OR submit the request the module's port definition must be strictly followed the name of the module in the file guess . do not include any Sdisplay statements in the module to prevent miscalculation sample data anso-ans3 is 0,1.42. input-input3 is 1.4, 1.2 both_correct is 1, color_correct is 3

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

DB2 11 The Ultimate Database For Cloud Analytics And Mobile

Authors: John Campbell, Chris Crone, Gareth Jones, Surekha Parekh, Jay Yothers

1st Edition

1583474013, 978-1583474013

More Books

Students also viewed these Databases questions

Question

please dont use chat gpt 3 2 4 .

Answered: 1 week ago