To copy one character
array into another
Program
#include<stdio.h>
void main()
{
char str1[81],
str2[81];
int k = 0;
printf("\nEnter
Any Data : ");
scanf("%s",
str1);
printf
("\nProcessing The String : ");
for (k = 0; str1[k]
!= '\0'; k++)
str2[k] = str1[k];
str2[k] = '\0' ;
printf ("\nThe
Two Stings Are :\n%s \t %s", str1, str2);
}
No comments:
Post a Comment