Skip to content
murmot

Results for “python while loop string methods examples list program site:wiki.python.org”

  • wiki.python.org

    ForLoop

    When running the above example, you can stop the program by pressing ctrl+c at the same time. As you can see, these loop constructs serve different purposes. The for loop runs for a fixed amount of times, while the while loop runs until the loop condition changes.

  • wiki.python.org

    While Loop - Python Wiki

    While loops, like the ForLoop, are used for repeating sections of code - but unlike a for loop, the while loop will not run n times, but until a defined ...

  • wiki.python.org

    Powerful Python One-Liners - Python Wiki

    ... python string and list methods. Here is an example from the homepage: Here ... 2026, Python Software Foundation. Made with Sphinx and Shibuya theme.

  • wiki.python.org

    For Loop - Python Wiki

    For loops¶. There are two ways to create loops in Python: with the for-loop and the while-loop. When do I use for loops¶. for loops are used when you have a ...

  • wiki.python.org

    Python Speed / Performance Tips

    ... example requires storing a mutable counter, for example a one-element list. ... String methods were introduced to the language in Python 2.0. These provide ...

  • wiki.python.org

    Perl Phrasebook - Python Wiki

    In Python, string methods are often used where Perl would use a regex. Among ... Note that sorting in Perl generates a new list, while in python sorting is done ...

  • wiki.python.org

    Templating - Python Wiki

    While templating is an important part of their function, determining the site structure and incorporating structural information in the output (for example ...