❔ 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
no one's going to download a zip generally, use $paste
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!
Ok, I was already expecting this xp
BlazeBin - phiaqtullymo
A tool for sharing your source code with the world!
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
but you have defined the array as Student, not as Person
In school?
Damn I'm stupid indeed Thx @dont
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.