You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the very least I'd suggest elaborating on what's expected. Of course the hint has it, but for those who don't want to go for hints 🙂 it would be helpful to clarify that what the exercise wants is to preserve the println! lines as-is too, i.e., to have that number + 2 piece intact.
@[email protected]: variables5 seems like cheating
I understand the concept of shadowing, but this example seems forced.
No, I didn't think of the solution at first and needed hint (and then felt like I was cheated)
@[email protected]:
Well, looking at it, it gets the idea across of shadowing, it's just a not-immediately-visibly-evident way of teaching it to what I would consider good teaching technique
The compiler also isn't quite lending much help, that actually may be considered a bug!
It teaches about shadowing, which is not really useful if used like this (nor is it appropriate at this point in the curriculum).
The text was updated successfully, but these errors were encountered: