Search code examples
pythonfunctionvariablesuppercaselowercase

How do I change the value of a variable to lowercase in Python?


How do I change the value of a variable to lowercase in Python?

For example, when "I study Python programming at KAIST Center for Gift Education." is the value of this variable, how do i make it "i study python programming at kaist center for gifted education"?


Solution

  • Just use the lower function

    string.lower()
    

    And here is the official documents.