Given the following structure declared:
struct MyStruct 
      public int x; 
      public int y; 
Is the following code correct:
class MyClass : MyStruct
No, it's impossible to inherit from a structure. All structures are implicitly sealed
C# Quiz
Start Quiz

or Read more about C# Quiz

Follow CodeGalaxy

Mobile Beta

Get it on Google Play
Send Feedback