I don't agree with the fact that the option
Replace line //4 and //5 with:
Integer i = map.get(b);
return i == null? 0:i;
is "not required" and I selected it instead of option
There is no need to change //4 and //5.
Infact, the question states "Choose changes that are absolutely necessary to take advantage of generics" and while my choice was not necessary for compilation, the page https://docs.oracle.com/javase/tutorial ... s/why.html reports that one of the advantages of generics is indeed Elimination of casts.
The question is infact ambiguos since absolute necessity may imply getting the most advantage, and I think it should be rewritten to "Choose the minimal changes necessary to take advantage of generics"
Or else the answer I gave should be accepted
