Ok, so my code works and it is fine, but nothing displayed and it still passed. I did tell it to print the given lines, just nothing was out put onto the screen. I think I understand why but just looking for some clarifications if any of you all have some.
Thanks in advance!
quick clarification
Under discussion
Comments (4)
- Popular
- New
- Old
You must be signed in to leave a comment
Krad
25 October 2020, 18:00
It'll pass without any output.
0
Maxine Hammett
26 June 2020, 14:16
Can you post your code? Maybe the instructions were to not ouput anything to the screen.
0
Brad Reed
26 June 2020, 17:05
package com.codegym.task.task06.task0602;
/*
Zombie cats, zombie dogs
*/
public class Cat {
protected void finalize(){
System.out.println("A Cat was destroyed");
}
public static void main(String[] args) {
}
//write your code here
}
class Dog {
//write your code here
@Override
protected void finalize() {
System.out.println("A Dog was destroyed");
}
}
0
Maxine Hammett
26 June 2020, 17:18
The only thing I can see if move the main method above cat's finalize
0