Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

change case python

_str = "Hello World!"

print(_str.upper()) 	# HELLO, WORLD!

print(_str.lower()) 	# hello, world!

print(_str.swapcase()) 	# hELLO wORLD!
Comment

how to change case of string in python

a = "Hello, World!"
print(a.upper()) 

#Output: HELLO, WORLD!

print(a.lower()) 
##Output:  hello, world!
Comment

PREVIOUS NEXT
Code Example
Python :: legend font size python matplotlib 
Python :: print flush python 
Python :: pandas print a single row 
Python :: python b before string 
Python :: install python 3.8 
Python :: python venv activate 
Python :: select columns to include in new dataframe in python 
Python :: how to print a column from csv file in python 
Python :: python random randint string 
Python :: how to add textbox in pygame window 
Python :: django migrate model 
Python :: how to make an empty variable in python 
Python :: remove dot from number python 
Python :: how to execute a python file from another python file 
Python :: python working directory 
Python :: Reading JSON from a File with Python 
Python :: python align label left 
Python :: MAKE A SPHERE IN PYTHON 
Python :: connectionrefusederror at /accounts/signup/ django allauth 
Python :: count_values in python 
Python :: index a dictionary python 
Python :: write lines python with line breaks 
Python :: How to append train and Test dataset in python 
Python :: loop indexing 
Python :: django-sslserver 
Python :: python array methods 
Python :: merging df vertically 
Python :: get turtle pos 
Python :: how to make dictionary in python 
Python :: seaborn pairplot python 
ADD CONTENT
Topic
Content
Source link
Name
3+3 =