Computer Science, asked by pratham4611, 1 year ago

if str = "INFORMATICS PRACTICES"....and str1 = "...FOR CLASSXI " write commands to print the output as 'informatics practices for classxi'

Answers

Answered by alinakincsem
0

c++ program to combine two strings and print them in lowercase

#include<iostream.h>

#include<conio.h>

void main()

{

clrscr();

string str("INFORMATICS PRACTICES");

string str("FOR CLASSXI");

//To change uppercase character into lowercase character, just add 32 in character in uppercase to convert it into lowercase.

for (int i = 0; i < str.size(); i++)

{

  str[i]=str[i]+32;              

}

for (int i = 0; i < str1.size(); i++)

{

  str1[i]=str1[i]+32;

}

cout<<str+" "+str1;

//combining two strings with a blank space between them

getch();

}


Answered by aashritha1710
1

String str="INFORMATICS PRACTICES";

String str1="  FOR  CLASS XI";

String strcon=str.concat(str1);

String lower=strcon.toLowerCase();

System.out.print(lower);

Similar questions