0

Recently came to be in need of do while loop in python, but couldn't find the syntax for it or does it even exist?

I tried below, but am getting syntax errors:

do{
    #c0d3 h3r3
} while(1=1)

or:

do:
    #c0d3 h3r3
while (1=1)

Can anyone tell me the syntax for it or tell me if it don't exist in python? I am in python3 django.

1 Answers1

0

Python doesn't have do-while loop, and you are assigning a value in your loop not comparing

vikAy
  • 314
  • 6
  • 15