Python Forum
Function producing no result
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Function producing no result
#3
Your code won't work because of the "continue". Continue is not needed for a while loop unless you want to skip parts of the while loop when a condition within the loop itself is met.

What you must do: Remove continue, and add an indent to all those statements within the while loop (i.e everything below while loop).

What is actually happening: The 'to be looped' is not even being considered within the loop. And even if it were, continue would make it so that they were never executed.

Continue makes it so that the other parts of the loop iteration are not executed.
Reply


Messages In This Thread
Function producing no result - by aditvaddi - Jul-09-2018, 11:35 PM
RE: Function producing no result - by Nwb - Jul-10-2018, 03:23 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  function giving different result with @functool.cache naughtysensei 3 1,893 Nov-25-2020, 03:12 PM
Last Post: naughtysensei

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020