-
Notifications
You must be signed in to change notification settings - Fork 0
/
Program.cs
207 lines (197 loc) · 5.34 KB
/
Program.cs
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using static System.Runtime.CompilerServices.RuntimeHelpers;
namespace A6
{
public struct TypeOfSize5
{
byte variable1;
byte variable2;
byte variable3;
byte variable4;
byte variable5;
}
public struct TypeOfSize22
{
TypeOfSize5 type1;
TypeOfSize5 type2;
TypeOfSize5 type3;
TypeOfSize5 type4;
byte variable1;
byte variable2;
}
public struct TypeOfSize125
{
TypeOfSize22 type22_1;
TypeOfSize22 type22_2;
TypeOfSize22 type22_3;
TypeOfSize22 type22_4;
TypeOfSize22 type22_5;
TypeOfSize5 type5_1;
TypeOfSize5 type5_2;
TypeOfSize5 type5_3;
}
public struct TypeOfSize1024
{
TypeOfSize125 type125_1;
TypeOfSize125 type125_2;
TypeOfSize125 type125_3;
TypeOfSize125 type125_4;
TypeOfSize125 type125_5;
TypeOfSize125 type125_6;
TypeOfSize125 type125_7;
TypeOfSize125 type125_8;
TypeOfSize22 type22_1;
byte variable1;
byte variable2;
}
public struct TypeOfSize32768
{
TypeOfSize1024 type1024_1;
TypeOfSize1024 type1024_2;
TypeOfSize1024 type1024_3;
TypeOfSize1024 type1024_4;
TypeOfSize1024 type1024_5;
TypeOfSize1024 type1024_6;
TypeOfSize1024 type1024_7;
TypeOfSize1024 type1024_8;
TypeOfSize1024 type1024_9;
TypeOfSize1024 type1024_10;
TypeOfSize1024 type1024_11;
TypeOfSize1024 type1024_12;
TypeOfSize1024 type1024_13;
TypeOfSize1024 type1024_14;
TypeOfSize1024 type1024_15;
TypeOfSize1024 type1024_16;
TypeOfSize1024 type1024_17;
TypeOfSize1024 type1024_18;
TypeOfSize1024 type1024_19;
TypeOfSize1024 type1024_20;
TypeOfSize1024 type1024_21;
TypeOfSize1024 type1024_22;
TypeOfSize1024 type1024_23;
TypeOfSize1024 type1024_24;
TypeOfSize1024 type1024_25;
TypeOfSize1024 type1024_26;
TypeOfSize1024 type1024_27;
TypeOfSize1024 type1024_28;
TypeOfSize1024 type1024_29;
TypeOfSize1024 type1024_30;
TypeOfSize1024 type1024_31;
TypeOfSize125 type125_1;
TypeOfSize125 type125_2;
TypeOfSize125 type125_3;
TypeOfSize125 type125_4;
TypeOfSize125 type125_5;
TypeOfSize125 type125_6;
TypeOfSize125 type125_7;
TypeOfSize125 type125_8;
TypeOfSize5 type5_1;
TypeOfSize5 type5_2;
TypeOfSize5 type5_3;
TypeOfSize5 type5_4;
byte variable1;
byte variable2;
byte variable3;
byte variable4;
}
public struct TypeForMaxStackOfDepth3000
{
TypeOfSize125 type125_1;
byte variable1;
byte variable2;
}
public struct TypeForMaxStackOfDepth1000
{
TypeOfSize125 type125_1;
TypeOfSize125 type125_2;
TypeOfSize125 type125_3;
TypeOfSize125 type125_4;
}
public struct TypeForMaxStackOfDepth100
{
TypeOfSize1024 type1024_1;
TypeOfSize1024 type1024_2;
TypeOfSize1024 type1024_3;
TypeOfSize1024 type1024_4;
TypeOfSize125 type125_2;
TypeOfSize125 type125_3;
TypeOfSize125 type125_4;
TypeOfSize125 type125_5;
TypeOfSize125 type125_6;
}
public struct TypeForMaxStackOfDepth10
{
TypeOfSize32768 type32768_1;
TypeOfSize1024 type1024_1;
TypeOfSize1024 type1024_2;
TypeOfSize1024 type1024_3;
TypeOfSize1024 type1024_4;
TypeOfSize1024 type1024_5;
TypeOfSize1024 type1024_6;
TypeOfSize1024 type1024_7;
TypeOfSize1024 type1024_8;
TypeOfSize1024 type1024_9;
}
public class TypeWithMemoryOnHeap
{
List<int[]> listOfArray;
public void Allocate()
{
listOfArray = new List<int[]>();
for (int i = 0; i < 1000; i++)
listOfArray.Add(new int[1000]);
}
public void DeAllocate()
{
listOfArray.Clear();
}
}
public struct StructOrClass1
{
public int X;
}
public class StructOrClass2
{
public int X;
}
public class StructOrClass3
{
public StructOrClass2 X = new StructOrClass2();
}
public enum FutureHusbandType : int
{
None =0 ,
HasBigNose =1 ,
IsBald =2 ,
IsShort = 4
}
public class Program
{
public static int GetObjectType(object o)
{
if (o is string)
return 0;
else if (o is Array)
return 1;
else if (o is int)
return 2;
return -1;
}
public static bool IdealHusband(FutureHusbandType fht)
{
if (((int)fht == 1) || ((int)fht == 2) || ((int)fht == 4) || ((int)fht == (1 | 2 | 4)))
return false;
else if (((int)fht == (1 | 2)) || ((int)fht == (1 | 4)) || ((int)fht == (2 | 4)))
return true;
return false;
}
public static void Main(string[] args)
{
}
}
}