Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

count how many loops that printed in python

tea = 100 #temperature of tea to start with
count = 0
while tea >= 70:
   print (str(tea) + " C")
   tea = tea - 10
   count += 1
print (" It's ready now ... ")
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #count #loops #printed #python
ADD COMMENT
Topic
Name
3+7 =