-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathGen1.cpp
62 lines (46 loc) · 797 Bytes
/
Gen1.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
57
58
59
60
61
62
#include<iostream>
using namespace std;
int main()
{
enum flag{
const1,const2,const3,const4,const5
};
cout<<sizeof(flag);//will print 4 as size of a integer on 32 and 64bit machines is 4 bytes
return 0;
}
//PROGRAM 1
// int x=4,y=x;
// int count =0;
//
// for(int i=1;i<4;++i) {
// count++; loop runs 3 times
// x+=x;
// }
//
// cout<<x<<endl; x is 32
// cout<<y*4<<endl;
// cout<<count;
//------------
//PROGRAM 2
// int func(int);//function prototyping
// int i = func(10);
// cout<<i<<endl;
// cout<<i--<<endl;
// cout<<i;
// return 0;
//-------------------
//PROGRAM-3
//int func();
//int i = func();
//
//cout<<i; //returns value of 1 ,as function called is true
//
//
//}
//
//int func() {
// _AX=1090;
//}
//int func(int x ) {
// return x++;
//}