Skip to content
murmot

Results for “python while loop string example code site:wiki.python.org error”

  • wiki.python.org

    Handling Exceptions - Python Wiki

    In the first example above, if you were using a catch-all exception clause and a user presses Ctrl-C, generating a KeyboardInterrupt, you don't want the program ...

  • wiki.python.org

    HandlingExceptions

    MoinMoin software is a good example of where general error catching is good. If you write MoinMoin extension macros, and trigger an error, MoinMoin will give you a detailed report of your error and the chain of events leading up to it.

  • wiki.python.org

    Simple Programs - Python Wiki

    keys()): if hour < activity_time: print (activities[activity_time]) break else: print ('Unknown, AFK or sleeping!') 11 lines: Triple-quoted strings, while loop.

  • wiki.python.org

    For Loop - Python Wiki

    Contrast the for statement with the ''while'' loop, used when a condition needs to be checked each iteration or to repeat a block of code forever. For example:.

  • wiki.python.org

    ForLoop

    Like the while loop, the for loop can be made to exit before the given object is finished. This is done using the break statement, which will immediately drop out of the loop and continue execution at the first statement after the block.

  • wiki.python.org

    Python Debugging Tools

    The debugger features various breakpoints, stepping modes, frames view, watches, evaluate expression tool and a debug console. Conditional and Exception ...

  • wiki.python.org

    Crashing Python - Python Wiki

    You can, for example, create code objects and give them arbitrary strings as their “bytecode”. There's no telling how successfully the interpreter will handle ...

  • wiki.python.org

    Getting Started - Python Wiki

    ... code examples, from one-liners to multi-class programs ... Learn Python – learning Python through XML, XSLT, and other practical code samples. While Loop – a ...