We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b6261d1 commit b4cab6aCopy full SHA for b4cab6a
solution/c#/Day14/Day14/LangExt/FizzBuzz.cs
@@ -7,12 +7,13 @@ public static class FizzBuzz
7
private const int Min = 1;
8
private const int Max = 100;
9
10
- private static readonly Map<int, string> Mapping =
11
- Map.create(
12
- (15, "FizzBuzz"),
13
- (3, "Fizz"),
14
- (5, "Buzz")
15
- );
+ private static readonly Dictionary<int, string> Mapping =
+ new()
+ {
+ { 15, "FizzBuzz" },
+ { 3, "Fizz" },
+ { 5, "Buzz" }
16
+ };
17
18
public static Option<string> Convert(int input)
19
=> IsOutOfRange(input)
0 commit comments