mirror of
https://github.com/markjprice/cs11dotnet7.git
synced 2026-04-04 13:57:37 +00:00
Initial commit
This commit is contained in:
parent
ca7684985d
commit
49bdd4dda1
60 changed files with 1527 additions and 30 deletions
14
vscode/Chapter02/Ch02Ex03Numbers/Ch02Ex03Numbers.csproj
Normal file
14
vscode/Chapter02/Ch02Ex03Numbers/Ch02Ex03Numbers.csproj
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Using Include="System.Console" Static="true" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
15
vscode/Chapter02/Ch02Ex03Numbers/Program.cs
Normal file
15
vscode/Chapter02/Ch02Ex03Numbers/Program.cs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
WriteLine("--------------------------------------------------------------------------");
|
||||
WriteLine("Type Byte(s) of memory Min Max");
|
||||
WriteLine("--------------------------------------------------------------------------");
|
||||
WriteLine($"sbyte {sizeof(sbyte),-4} {sbyte.MinValue,30} {sbyte.MaxValue,30}");
|
||||
WriteLine($"byte {sizeof(byte),-4} {byte.MinValue,30} {byte.MaxValue,30}");
|
||||
WriteLine($"short {sizeof(short),-4} {short.MinValue,30} {short.MaxValue,30}");
|
||||
WriteLine($"ushort {sizeof(ushort),-4} {ushort.MinValue,30} {ushort.MaxValue,30}");
|
||||
WriteLine($"int {sizeof(int),-4} {int.MinValue,30} {int.MaxValue,30}");
|
||||
WriteLine($"uint {sizeof(uint),-4} {uint.MinValue,30} {uint.MaxValue,30}");
|
||||
WriteLine($"long {sizeof(long),-4} {long.MinValue,30} {long.MaxValue,30}");
|
||||
WriteLine($"ulong {sizeof(ulong),-4} {ulong.MinValue,30} {ulong.MaxValue,30}");
|
||||
WriteLine($"float {sizeof(float),-4} {float.MinValue,30} {float.MaxValue,30}");
|
||||
WriteLine($"double {sizeof(double),-4} {double.MinValue,30} {double.MaxValue,30}");
|
||||
WriteLine($"decimal {sizeof(decimal),-4} {decimal.MinValue,30} {decimal.MaxValue,30}");
|
||||
WriteLine("--------------------------------------------------------------------------");
|
||||
|
|
@ -17,6 +17,9 @@
|
|||
},
|
||||
{
|
||||
"path": "Vocabulary"
|
||||
},
|
||||
{
|
||||
"path": "Ch02Ex03Numbers"
|
||||
}
|
||||
]
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue