- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Converting to upper case in Java.
This method has two variants. The first variant converts all of the characters in this String to upper case using the rules of the given Locale. This is equivalent to calling toUpperCase(Locale.getDefault()).
The second variant takes a locale as an argument to be used while converting into upper case.
Example
import java.io.*; public class Test { public static void main(String args[]) { String Str = new String("Welcome to Tutorialspoint.com"); System.out.print("Return Value :"); System.out.println(Str.toUpperCase()); } }
Output
Return Value :WELCOME TO TUTORIALSPOINT.COM
- Related Articles
- Program for converting Alternate characters of a string to Upper Case.\n
- How to transform List string to upper case in Java?
- MySQL Query to change lower case to upper case?
- Converting strings to snake case in JavaScript
- Converting any case to camelCase in JavaScript
- How to convert Lower case to Upper Case using C#?
- How to convert Upper case to Lower Case using C#?
- Java program to count upper and lower case characters in a given string
- Convert a C++ String to Upper Case
- Java Program to check whether the entered character a digit, white space, lower case or upper case character
- Moving all Upper case letters to the end of the String using Java RegEx
- Converting digits to word format using switch case in C language
- How to check if a character is upper-case in Python?
- How to convert a string into upper case using JavaScript?
- Converting String to StringBuilder in Java

Advertisements