This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Console.WriteLine("Hello, World!"); | |
| static void GetADateOnly(int dayNo, out DateOnly result) { | |
| if (dayNo == 0) { throw new ArgumentOutOfRangeException(nameof(dayNo)); } | |
| var t = DateOnly.FromDateTime(DateTime.Now); | |
| if (dayNo < 0) { | |
| // Requied as DateOnly has a field... else get CS0177 on the next line | |
| //result = t; |