blob: 8a934554dc595d726c709f2336386d6e2e311c67 (
plain)
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
|
#include <iostream>
/*
*
* 4.30
*
* Wow! This was a tricky question.
*/
int f() {
return 1;
}
struct ddd {
int mem[10];
};
int main () {
struct ddd ggg;
struct ddd *p = ⋙
int i = 0;
int x = 0;
int y = 0;
unsigned int a = 0;
unsigned int b = 0;
std::cout << sizeof (x) + y << std::endl;
std::cout << sizeof (p->mem[i]) << std::endl;
std::cout << (sizeof (a) < b) << std::endl;
std::cout << sizeof (f()) << std::endl;
return 0;
}
|