92
Console.WriteLine($"An instance of {array[0].GetType()} is {bytesPerInstance} bytes.");
1
using System;
2
3
public class Program
4
{
5
private const bool ShowAnswer = true;
6
7
public static void Main()
8
{
9
// homework:
10
// 1. put the method calls in order of byte size
11
// 2. fill in the comment with the byte size
12
MeasureBytes<decimal>(); //
13
MeasureBytes<byte>(); //
14
MeasureBytes<short>(); //
15
MeasureBytes<double>(); //
16
MeasureBytes<int>(); //
17
MeasureBytes<Dimensions>(); //
18
MeasureBytes<Address>(); //
19
MeasureBytes<DimensionsUnit>(); //
20
MeasureBytes<long>(); //
21
MeasureBytes<DateTime>(); //
22
MeasureBytes<DimensionsBigger>(); //
23
}
24
Cached Result
20 siglos son 2000 años o 730480 dias o 17531520 horas
18446744073709551615
18446744073709551615