Consider what would be if this assignment was legal:
In this code in line 6 we get Object from the list that is declared that can contain only Numbers.
This breaks program with ClassCastException.
To avoid situation like this, compiler prevents assignment in line 04.
Think of how stupid the average person is. And how half of them are stupider than that. But who reads this tiny ad?
Programmatically Create PDF Using Free Spire.PDF with Java