CodeGym /Courses /Java Collections /Tasks | Level 5 | Lesson 10

Tasks | Level 5 | Lesson 10

Java Collections
Level 5 , Lesson 10
Available
32
Task
Java Collections, level 5, lesson 10
Locked
What is ClassLoader?
Implement the getAllAnimals method. The method's pathToAnimals parameter is the absolute path to the directory where the compiled classes are saved. The path doesn't necessarily have a "/" at the end. Not all classes inherit the Animal interface.
8
Task
Java Collections, level 5, lesson 10
Locked
extends vs super
All of the methods add the source to the destination. Add ?, extends, and super where needed: 1) methodOne must work with the same type; 2) methodTwo must add any descendants of T to a list that can only store T objects.
8
Task
Java Collections, level 5, lesson 10
Locked
Wildcards for collections
The Solution class has 4 methods for working with lists: sum - Sums up all numeric elements of the list, multiply - Multiplies all numeric elements of the list, concat - Concatenates all elements of the list into a single String.
Comments (4)
TO VIEW ALL COMMENTS OR TO MAKE A COMMENT,
GO TO FULL VERSION
Andrei Level 41
20 July 2021
Task 'extends vs super' was a great task! Really enjoyed applying the knowledge gained so far. Easy but helps strengthen the information learned. 👍
allthemore Level 41
12 August 2020
Generics are kind of tricky, I wish you added more tasks to practice!
fzw Level 41, West University Place, United States
6 May 2020
Why can't we simply use URLClassLoader for last problem?
Alexandre Lalancette Level 41, Quebec, Canada
8 February 2020
Last exercise is very challenging. Someone can share a hint or two on how to solve it?