-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path5_question.cpp
56 lines (51 loc) · 1.03 KB
/
5_question.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#include<iostream>
#include<string>
#include<conio.h>
using namespace std;
class strin
{
private:
string lName, fName;
public:
/* getFname()
{
cout<<"Enter your First Name and Last Name"<<endl;
cin>>fName;
cout<<fName<<endl;
return f;
}
getLname()
{
cout<<"Enter your Last Name"<<endl;
cin>>lName;
return l;
}*/
strinn(string lN,string fN)
{
//string s3;
// lN=fN;
// strcpy(fN, lN);
cout<<fN<<lN<<endl;
cout<<fN.length();
//cout<<"fName="<<fN;
//cout<<"lName="<<lN;
//cout<<"length:"<<strlen(fN);
// strcpy(fN,lN);
// cout<<lN;
}
};
int main()
{
string b1,b2;
//string f,l;
//f=b2.getFname();
//l=b2.getLname();
//b2.strinn(f,l);
// strcpy(fN,lN);
//cout<<lN;
b1="anand";
b2="nayak";
// strcpy(b2,b1);
cout<<b2;
getch();
}