#include<iostream.h> //cout,cin, << , >>
#include<conio.h>
#include<string.h> //for strlen()
#include<stdio.h> //for gets() and puts()
#include<conio.h>
#include<string.h> //for strlen()
#include<stdio.h> //for gets() and puts()
/*..Main Function Start’s…*/
void main()
{
char string[50];
int length;
clrscr();
cout<<”\n enter a string in minimum 50 characters:”;
gets(string);
length=strlen(string);
puts(string);
cout<<”\n the length of the string is:”<<length<<”\n”;
getch();
}
void main()
{
char string[50];
int length;
clrscr();
cout<<”\n enter a string in minimum 50 characters:”;
gets(string);
length=strlen(string);
puts(string);
cout<<”\n the length of the string is:”<<length<<”\n”;
getch();
}
/*..Main Function End’s….*/
THE OUTPUT IS
No comments:
Post a Comment