• ###### mawhcommented on "Statistics for an Athletic Association" kata

Range applies to the full time span indicated, so if the fastest time was 1:02:03 and the slowest time was 3:05:07 then the time range is 2:03:04.
If the fastest time was 1:30:40 and the slowest time was 2:20:30 then the time range is 0:49:50.

In real world terms the range question is asking "how long did the person at the finish line with the stopwatch have to wait, between the moment the fastest runner finished, and the moment the slowest runner finished? How much time passed between the winner finishing and the last person finishing?"

You have to do time math on the entire period of time, not just the hours/minutes/seconds components separately

• ###### mawhcommented on "Statistics for an Athletic Association" kata

Managed to get it done in 1 line of best janktice ;)

• ###### miggycodercommented on "Statistics for an Athletic Association" kata

My python code for this kata is 100% best practice fr fr

(hint: its 113 lines long with janky code)

• ###### mawhcommented on "Statistics for an Athletic Association" kata

Can ye chuck a bit of markdown around the `""` empty strings in If the given string is "" you will return "" so that it doesn't read like some accidentally escaped version of the phrase 'If the given string is "you will return"' ?

• ###### frostbytcommented on "Death by Coffee" csharp solution

Thanks for the tips, I haven't really done any programming in awhile so I'm quite rusty.

• ###### mawhcommented on "Death by Coffee" csharp solution

Tip: When using interpolated strings or string.Format, you don't need to format your numbers by calling ToString; you can just pass the format in after a colon in the interpolated placeholder e.g. `Convert.ToInt32(\$"{year:D4}{month:D2}{day:D2}");`. `hexNum` could also have been formed with maths rather than string parsing (`year*10000 + month*100 +day`)

• ###### mawhcommented on "Death by Coffee" csharp solution

In C# you can declare numbers in hex e.g. `int valueCoffee = 0xCAFE` instead of parsing from string

• ###### mawhcommented on "Are they the "same"?" csharp solution

Typo: should read "a is a superset of b"

• ###### osoncommented on "Crude Machinery and a Command Line Interface" kata

Absolutley! :D
I fixed the description. Your comment also inspired me to make the siren sounds more prominent :)

• ###### mawhcommented on "Friend or Foe?" csharp solution

This comment is hidden because it contains spoiler information about the solution

• ###### mawhcommented on "Friend or Foe?" csharp solution

This comment is hidden because it contains spoiler information about the solution

• ###### mawhcommented on "Crude Machinery and a Command Line Interface" kata

Tricky, a phrase like "the siren will go off" - does it mean it starts making a noise, or that it stops making a noise?

• ###### mawhcommented on "Dead Ants" kata

LOL

• `A`bdomen
• `N`oggin
• `T`horax
• ###### mawhcommented on "Dead Ants" kata

LOL at the cheese sandwich; very subtle

• ###### mawhcommented on "Dead Ants" kata

It doesn't really matter which part you define as head and which part as body. The problem description states if you find 2 heads and 1 body, then it's 2 ants.. (If you find 2 heads and 2 bodies then it's 2 ants.. If you find 2 heads and 3 bodies then it's 3 ants.. etc)