6 kyu

Reflection #2 - Give me all methods

Description
Loading description...
Fundamentals
Object-oriented Programming
Reflection
Metaprogramming
  • Please sign in or sign up to leave a comment.
  • dfhwze Avatar

    Do something about the error message. Print the expected method names. Also, why does (all) methods not include "ReferenceEquals" or any other method in the flatten hierarchy?

  • FArekkusu Avatar

    C# 8 should be enabled.

  • NikoKushnarenko Avatar

    I have a problem during solving that kata could someone help me?

    Different count of Methods 6 vs 9 Expected and actual are both <System.Linq.OrderedEnumerable`2[System.String,System.String]> Values differ at index [2] Expected string length 8 but was 11. Strings differ at index 0. Expected: "Finalize" But was: "GetHashCode" -----------^

    • hobovsky Avatar

      It seems your solution does not return some methods. The class has 9 methods, but your function returned only 6 of them. Three more are missing.

  • andrewcdudas Avatar

    I had never dealt with reflection before, and beyond being aware of the term I had no idea what it actually was.

    It took me far too long to figure out how to return ALL of the methods and I learned way more because of it, good call on that one.

  • donaldsebleung Avatar

    Thanks for the educational Kata; I thoroughly enjoyed it and learned quite a lot about reflection in C# :D Prior to this Kata, I only knew reflection in PHP which isn't quite the same as C# :p