[Tutor] For - if - else loop; print selective output

Alan Gauld alan.gauld at btinternet.com
Wed Oct 24 19:19:10 CEST 2012


On 24/10/12 17:59, Saad Javed wrote:
> Thanks!
>
> If not matched: <---- does it mean that "if the value of matched is not
> true, print Not found"?

Yes exactly. matched starts off as False and will remain that way until 
a match is found at which point we set it to True.


-- 
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/



More information about the Tutor mailing list