Learnerslesson
   JAVA   
  SPRING  
  SPRINGBOOT  
 HIBERNATE 
  HADOOP  
   HIVE   
   ALGORITHMS   
   PYTHON   
   GO   
   KOTLIN   
   C#   
   RUBY   
   C++   




upper( ) FUNCTION


upper( ) Function


The upper( ) Function is used to convert all the characters/letters of the String in lower case.


Example :


x = "HeLLo"
y = x.upper()
print("The String in upper case is ",y) 


Output :



  The String in upper case is HELLO

In the above code, we have declared a String 'HeLLo', in which the letters 'e' and 'o' are in lower case.


x = "HeLLo"

java_Collections

So, we have used the 'upper( )' Function to convert them to upper case and assign to a variable 'y'.


y = x.upper( )

java_Collections