Skip to content

Commit 103fefe

Browse files
WilliamAntonRohmmairaw
authored andcommitted
updating for Try .NET (#1864)
1 parent 013ce88 commit 103fefe

File tree

2 files changed

+18
-17
lines changed

2 files changed

+18
-17
lines changed
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
// <Snippet3>
2-
using System;
1+
using System;
32

43
public class Example
54
{
65
public static void Main()
76
{
7+
// <Snippet3>
88
long number1 = 1635429;
99
int number2 = 16203;
1010
double number3 = 1639.41;
@@ -20,11 +20,11 @@ public static void Main()
2020
Object.ReferenceEquals(t, number3.GetType()));
2121
Console.WriteLine("Type of number1 and number4 are equal: {0}",
2222
Object.ReferenceEquals(t, number4.GetType()));
23+
24+
// The example displays the following output:
25+
// Type of number1 and number2 are equal: False
26+
// Type of number1 and number3 are equal: False
27+
// Type of number1 and number4 are equal: True
28+
// </Snippet3>
2329
}
2430
}
25-
// The example displays the following output:
26-
// Type of number1 and number2 are equal: False
27-
// Type of number1 and number3 are equal: False
28-
// Type of number1 and number4 are equal: True
29-
// </Snippet3>
30-
Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
1-
// <Snippet2>
2-
using System;
1+
using System;
32

43
public class Example
54
{
65
public static void Main()
76
{
7+
// <Snippet2>
88
object[] values = { "word", true, 120, 136.34, 'a' };
99
foreach (var value in values)
1010
Console.WriteLine("{0} - type {1}", value,
1111
value.GetType().Name);
12+
13+
// The example displays the following output:
14+
// word - type String
15+
// True - type Boolean
16+
// 120 - type Int32
17+
// 136.34 - type Double
18+
// a - type Char
19+
// </Snippet2>
1220
}
1321
}
14-
// The example displays the following output:
15-
// word - type String
16-
// True - type Boolean
17-
// 120 - type Int32
18-
// 136.34 - type Double
19-
// a - type Char
20-
// </Snippet2>
2122

0 commit comments

Comments
 (0)