Open Mildred-ui opened 3 years ago
I believe for this question you just need to declare and construct the appropriate variables and structures to get the diagram shown. So the args taken in by Main for this question is not relevant. As for Immutability, I think it depends on the question haha, but for this case, you're referencing the same objects (Library's loan attribute uses bk and br directly), so immutability is not used here (you don't have to create a copy, which will add to the stack if I'm not wrong and that's not what the question wants). Once again, I think this depends on the question!
Hi all!
Just want to clarify that for coding questions like this, do we have to ensure immutability? Also, in this particular case, should I decide what is the args takes in by Main? Or the question only need a structure?
Thx in adv :)