Thursday, April 8, 2021

ICSE COMPUTER SCIENCE SPECIMEN PAPER | QUESTION NO 6 | DO WATCH THE VIDEO

 


import java.util.*;
class icse_specimen_2
{
public static void main(String[] args)
{
Scanner sc = new Scanner(System.in);
String s = sc.nextLine();
s.trim();
s=" "+s;
s= s.toUpperCase();
String newword="";
for(int i=0;i<s.length();i++)
{
char c = s.charAt(i);
if(c==' ')
{
char next_char=s.charAt(i+1);
newword=newword+next_char+".";
}
}
System.out.println(newword);
}
}



No comments:

Post a Comment

ICSE COMPUTER SCIENCE SPECIMEN PAPER | QUESTION 7 | PLEASE DO WATCH THE VIDEO

  import  java.util.*; class icse_specimen_1 {     public static void main(String[] args)     {         Scanner sc1 = new Scanner(System.in)...