I solved the task so i don't want to post the correct code. I stillt don't get the output. The output is like: Tiger - TIGER Missy - MISSY (..) Why isn't the output something like this: Missy - com.example.übung.Übung$Cat@681a9515 Tiger - com.example.übung.Übung$Cat@3af49f1c (...) I understand that the override method turns the name into uppercase letters, but not why the object description changes. the class looks like this : ( public static class Cat { String name; public Cat(String name) { this.name = name; } @Override public String toString() { return name != null ? name.toUpperCase() : null; } } the output is generated like this: or (Map.Entry<String, Cat> pair : map.entrySet()) { System.out.println(pair.getKey() + " - " + pair.getValue()); } Maybe someone can help to understand. Thanks in advance.