Computer Science, asked by Krishna2880, 5 months ago

1. Write a program to ask a user to input a word and convert the word into all uppercase
letters. Print the output n the screen.​

Answers

Answered by surulivel
13

Answer:

import java.util.*;

class abc{

Scanner s=new Scanner(System.in);

System.out.print("enter a word");

String wd=s.nextLine();

for(int i=0;i<wd.length();i++)

{ si=wd.charAt(i);

sc=Character.toUpperCase(si);

wd2=" "+sc;

}

System.out.print( " " +wd2);

}

Similar questions