1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
andrew11 [14]
3 years ago
12

Suppose we have a String object called myString. Write a single line of Java code

Computers and Technology
1 answer:
VikaD [51]3 years ago
5 0

Answer:

myString=myString.toUpperCase();

Explanation:

In java to change all characters of a string to upper case we use .toUpperCase() method.It will convert string to upper case.

Implementation in java.

import java.util.*;

class Solution

{

public static void main (String[] args) throws java.lang.Exception

{

   try{

Scanner scr=new Scanner(System.in);

System.out.print("Enter a string:");

String myString=scr.nextLine();

myString=myString.toUpperCase();

System.out.println("string in upper case : "+myString);

         }catch(Exception ex){

       return;}

}

}

Output:

Enter a string:hello

string in upper case : HELLO

You might be interested in
Fill in the blanks with the correct words.
viva [34]

Answer:

1) Horizontal

2) Insert

3) Adjustment

4) Cell Style

5) Option-numeric

Explanation:

4 0
2 years ago
What is the most commen code used in games?
melamori03 [73]
Uw12e72jeu3j3gd72hd21heys1738he73ue73jdba
3 0
3 years ago
Custom parameters 1, 2 and 3 provide the same end value for all keywords. true or false?
lesya [120]
Is a Microsoft Bing ads certification Exam question.
I think that the correct answer is:
False

Source and more info: <span>https://goo.gl/JUw7Bw</span>
3 0
2 years ago
BIm computer class I need answers please
egoroff_w [7]

Answer:

I think the 3RD

Explanation:

The  reason why I think that is because the other once are not written correctly.

8 0
3 years ago
Read 2 more answers
Giving 5 stars, a Thanks, 80 points, and Branliest to whoever answers them correctly.
Mrac [35]

Answer:

Explanation:

The answer is ludonarrative.

Please mark me brainliest.

4 0
2 years ago
Other questions:
  • G=D+(A+C^2)*E/(D+B)^3 Rewrite the above formula in terms of doing concurrent processing using cobegin and coend to identify thos
    12·1 answer
  • If you quote an author from a website in a paper, it will be important to create a _____ in your writing to give them credit for
    7·2 answers
  • What daily life problems does the algorithm quicksort solve?
    14·1 answer
  • A two-dimensional array can be viewed as ___________ and _____________.
    10·1 answer
  • Movies may depict larger-than-life situations, such as calamities, superheroes, and spaceships. A helps show such extraordinary
    11·1 answer
  • In a linked chain implementation of a queue, the performance of the enqueue operation
    10·1 answer
  • Holly the Hacker has a list of 100,000 common passwords. She wants to use this list to break into UNIX-like systems that use a p
    14·1 answer
  • What is closeable interface in java.
    12·1 answer
  • When one loop appears inside another, the loop that contains the other loop is called the ____ loop. Group of answer choices ind
    15·1 answer
  • Why womt this code work????
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!