#include<iostream>
using namespace std;
void string_length()
{
char str[100],*p;
int i=0;
cout<<"Enter Strings Below 100:"<<endl;
cin>>str;
p=str;
while(*p !='\0')
{
i++;
p++;
}
cout<<"Length Of String Is:"<<i<<endl;
}
int main()
{
string_length();
return 0;
}

No comments:
Post a Comment