Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I want to add timer to this program like the user has set amount of time to input the value of choice in other words

I want to add timer to this program like the user has set amount of time to input the value of choice in other words if the player don't hit the keys in givien time then the game will quit.. c++ please

image text in transcribed

usleep (10000000); if (option ='p. Il option =='P'){ char myArray[2]121 1'O,0','0','' char choice; while(true) ? Implicit conversion loses integer precision,'time-t' (aka 'long') to 'unsigned int int x, y char temp; for (int 1-0 ; 12 ;i++) { for (int j-0;jchoice; if && myArray[0][0] '*') && myArray[1][1] Il (choice-- '*')) && myArray[0][1] '*') | | (choice myArray[1][0] ((choice *') =- "Q =- "W' = ?? ?' && | | (choice 'S' { = = score += 1; if ((choice 'x') | | (choice && myArray[0][1] 'x') II (choice myArray[1][0] myArray[0][0] )I(choice 'S&& myArray[1][1])) != Q' && = !- "W' = != 'A B& == cout "whoops! you hit the wrong key"

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

Making Databases Work The Pragmatic Wisdom Of Michael Stonebraker

Authors: Michael L. Brodie

1st Edition

1947487167, 978-1947487161

More Books

Students also viewed these Databases questions