Question

Consider the followings: if ( (ans == 'Y' && errors < 5) || numTries < 10...

Consider the followings:

   if ( (ans == 'Y' && errors < 5)  ||  numTries < 10 )  // note uppercase 'Y'
      count++;

Which combinations of values results in count being incremented after the statement is complete?

(Select all that apply.)

ans = 'Y' (upper case)

errors = 3

numTries = 10

ans = 'y' (lower case)

errors = 4

numTries = 5

   ans = 'Y' (upper case)
   errors = 5
   numTries = 10
   ans = 'N'
   errors = 7
   numTries = 5
   ans = 'Y' (upper case)
   errors = 100
   numTries = 22
0 0
Add a comment Improve this question Transcribed image text
Know the answer?
Add Answer to:
Consider the followings: if ( (ans == 'Y' && errors < 5) || numTries < 10...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT