I have to setup a while loop for a question in my class but i'm not sure how to do it (lab is moving a little quicker than lecture)
We have to take the word Python and set up a while loop so that once it reaches the letter h, it displays:
"This is pass block"
"Current Letter:" <print letter here>
When does the condition in the while statement (i.e. int i = 0) become false to break the while loop?
I'm slightly surprised that the loop runs even once;
The value of a condition that is an initialized declaration in a statement other than a switch statement is the value of the declared variable implicitly converted to type bool.
I would have expected that integer value zero converted to type bool would come out as false. Every day is a school day.
I'm sorry, i'm a total beginner when it comes to c++. I took a stab at it and apparently it's completely wrong. Can you please help me figure out what I need to do?