- 1
Write a program to read 2 strings and first string appends on the 2nd string
for eg.if str1 is GOOD and str2 is MORNING the result should be MORNINGGOOD
3 Respostas
+ 3
#include<cstring>
#include<iostream>
int main()
{
char a[10]="hi" , b[10]="there!!";
cout<<strcat(b,a);
}
//output there!!hi
0
string a="hi", b="there!";
cout<<b+a;
//output there!hi
0
no using strcat (appends!)