78 446
Assignments Done
Successfully Done
In September 2019

Answer to Question #15376 in Java | JSP | JSF for Royce

Question #15376
ArrayList<Double>a; a=new ArrayList<Float>(); What is the error in the code segment?
Expert's answer
You must use only object types in generic class. Example:
a=new ArrayList<Float>() where Float - object type (float - simple type)

Likewise you must use Integer, Double, Long, Byte, String etc.

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!


No comments. Be first!

Leave a comment

Ask Your question

Privacy policy Terms and Conditions