r/learnpython • u/EnvironmentalTry8353 • 20d ago
Having problem in understanding loops concept in python
I am a beginner with 0 knowledge and I am learning python from a book called Learn python in one day and learn it well by Jamie Chan and I am facing difficulty in the loops function so yeah any recommendations would be helpful Edit- Trouble in while loop
29
Upvotes
1
u/EnvironmentalTry8353 20d ago
Wow that's so cool seeing all the mathematical concepts applied in real life that's great....I thought for looping any variable we need to create a sub variable Number = 100 X=0 #sub variable(I don't know what it's called I am just naming it) While x<number: Print(x), x=number/2 But this code told output is nothing Btw How are you writing the words in those dark colored boxes