We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Day 4: Class vs. Instance
Day 4: Class vs. Instance
Sort by
recency
|
1892 Discussions
|
Please Login in order to post a comment
I think my solution it's ok, a blank line is being printed at the end of execution but I'm not allowed to modify that code and because of that I think the outcome is a "wrong" answer, please let me know if you see something wrong with my solution
the code doesn't print the you are old statement what could be the reason` import java.io.; import java.util.;
public class Person { private int age;
} `
This is broken for Typescript!
Guys! this is my code what am i doing wrong? public class Solution {
} /* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution. */ public class Person { private int age;
public void yearPasses(){ age = age + 1; } public void amIOld() { if(age < 13) { System.out.println("You are young..");
}