21
1
using System;
2
3
public class Program
4
{
5
public static void Main()
6
{
7
int currentHour = 0; // current hour between 0 - 23
8
9
if(/*boolean statement A*/)
10
{
11
Console.WriteLine("Good Morning");
12
}
13
else if (/*boolean statement B*/)
14
{
15
Console.WriteLine("Good Afternoon");
16
}
17
else
18
{
19
Console.WriteLine("Good Night");
20
}
21
}
Cached Result
Json.NET version: Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed
Initial JSON:
[
{
"MyStringArray": [
"stringInput1",
"stringInput2"
],
"MyCharArray": [
"a",
"b",
"c",
"."
],
"MyString": "dummy",
"MyClass3Object": [
{
"MyString": "ListInput1",
"MyRegex": {
"Pattern": "[A-Z]",
"Options": 0
}
},
{
"MyString": "ListInput2",
"MyRegex": {
"Pattern": "[0-9]",
"Options": 0
}
}
]
}
]
Deserialized and re-serialized JSON:
[
{
"MyStringArray": [
"stringInput1",
"stringInput2"
],
"MyCharArray": [
"a",
"b",
"c",
"."
],
"MyString": "dummy",
"MyClass3Object": [
{
"MyString": "ListInput1",
"MyRegex": {
"Pattern": "[A-Z]",
"Options": 0
}
},
{
"MyString": "ListInput2",
"MyRegex": {
"Pattern": "[0-9]",
"Options": 0
}
}
]
}
]
Initial and re-serialized are equivalent.
Initial JSON:
[
{
"MyStringArray": [
"stringInput1",
"stringInput2"
],
"MyCharArray": [
"a",
"b",
"c",
"."
],
"MyString": "dummy",
"MyClass3Object": [
{
"MyString": "ListInput1",
"MyRegex": {
"Pattern": "[A-Z]",
"Options": 0
}
},
{
"MyString": "ListInput2",
"MyRegex": {
"Pattern": "[0-9]",
"Options": 0
}
}
]
}
]
Deserialized and re-serialized JSON:
[
{
"MyStringArray": [
"stringInput1",
"stringInput2"
],
"MyCharArray": [
"a",
"b",
"c",
"."
],
"MyString": "dummy",
"MyClass3Object": [
{
"MyString": "ListInput1",
"MyRegex": {
"Pattern": "[A-Z]",
"Options": 0
}
},
{
"MyString": "ListInput2",
"MyRegex": {
"Pattern": "[0-9]",
"Options": 0
}
}
]
}
]
Initial and re-serialized are equivalent.