digital-garden/notes/Собеседования/Задачи/Задача 6.md

38 lines
489 B
Markdown
Raw Normal View History

2024-06-13 21:01:37 +03:00
---
parents:
- "[[Вопросы для собеседование Java]]"
---
```java
public class Train {
public static void main() {
println(null);
}
private static void println(Parent o) {
System.out.println(o);
}
private static void println(Child o) {
System.out.println(o);
}
private static void println(Object o) {
System.out.println(o);
}
}
class Parent {
}
class Child extends Parent {
}
```
%%
null
%%