C
C#8mo ago
LeviCoding

❔ I'm stuck with Polymorfism

So In my program we have a class Persoon and a class student and class leerkracht. a student and leerkracht is a persoon. I need to keep a list of personen and leerkrachten. I can implement student but not leerkracht. Can someone help. If you see code you will understad
9 Replies
SG97
SG978mo ago
no one's going to download a zip generally, use $paste
MODiX
MODiX8mo ago
If your code is too long, you can post to https://paste.mod.gg/ and copy the link into chat for others to see your shared code!
LeviCoding
LeviCoding8mo ago
Ok, I was already expecting this xp
LeviCoding
LeviCoding8mo ago
BlazeBin - phiaqtullymo
A tool for sharing your source code with the world!
LeviCoding
LeviCoding8mo ago
this works? Could not add all the classes, but the problem is that School.Personen.Add(new Leerkracht("Danny")); not works Probably the problem is in the School class or Persoon class? I'm not ssure
WEIRD FLEX
WEIRD FLEX8mo ago
but you have defined the array as Student, not as Person
LeviCoding
LeviCoding8mo ago
In school? Damn I'm stupid indeed Thx @dont
Accord
Accord8mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.