Implement strcmp

Answer Posted / sanjith

#inclde<string.h>
int d;
class test
public: void read()
void cmb()
};
void test::read()
{ cout<<"Enter the first string:";
cin>>s1;
cout<<"Enter the second string";
cin>>s2;
}
void test::cmb()
{
d=strcmp(s1,s2);
}
main()
{
test t1,t2;
t1.read();
t2.cmb();
t2.print();
}

Is This Answer Correct ?    1 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is c++ pass by reference or value?

579


What do you mean by global variables?

581


What is stack unwinding?

617


What are containers in c++?

581


What is c++ prototype?

597






What is unary operator? List out the different operators involved in the unary operator.

599


What is one dimensional array in c++?

592


What is token c++?

592


What is conditions when using boolean operators?

607


By using c++ with an example describe linked list?

615


If I is an integer variable, which is faster ++i or i++?

600


What are the extraction and insertion operators in c++?

575


Describe the process of creation and destruction of a derived class object?

653


What is a terminating character in c++?

784


Is it possible to write a c++ template to check for a function's existence?

586