Can enum implement interface in C#?

After a bit of experimentation, my conclusion is that it’s possible for an enum to implement an interface if it doesn’t have methods . But you cannot create it in C#. Using that enum in a C# program is funny: if you check if the value “is IMyInterface”, the compiler warns you that the expression is never of that type.

Sizin İçin Seçtik  Nihai mal ne demektir?

Leave a Reply

Your email address will not be published. Required fields are marked *