Подскажите что не так???
package com.javarush.task.task20.task2028;
import java.util.List;
public class Solution {
public static void main(String[] args) {
List<String> list = new CustomTree();
for (int i = 0; i < 17; i++) {
list.add(String.valueOf(i));
}
for (CustomTree.Entry e :
((CustomTree) list).list) {
String parent="zalupa";
String name=e.elementName;
if (e.parent!=null){
parent=e.parent.elementName;
}
System.out.println("Name - "+name+" Parent - "+parent);
}
System.out.println("The list size is " + list.size());
System.out.println("The expected parent is 3. The actual parent is " + ((CustomTree) list).getParent("8"));
System.out.println("The expected parent is null. The actual parent is " + ((CustomTree) list).getParent("20"));
}
}