Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
How will this line compile? List is an interface, there is no new keyword and its missing brackets at the end.
For answer 1 and 2 I agree with you.
You can never instantiate a wildcard type, this is why this line doesn't compile.
The 2nd line doesn't compile as aa might not have been initialized. Otherwise it compiles fine which makes answer 3 correct...
Hi Ankit, assignment means, option2 at Line 42 is assigning at Line 26 "list" reference variable (or) reference variable "aa" at line 54 is assigning to bb (or) both ?
Technically when you pass some variables in a method call, its not assignment. But most of the rules that apply to assignment will apply to it. So in this case, rules of generics apply to both line 54 and 42...