1).Is Object class abstract or not?
2).Is main method(public static void main(String args[])low
priority thread or high priority thread?
Answer Posted / harinath.b (sai sudhir p.g co
1) Object class is not an abstract class.The default
implementation is provided by javasoft.If we want we can
override the methods of Object class.
Ex class Top extends Object{
public String toString()
{
return "Java is ruling the WEB";
}
}
2)main() method is having the normal priority.To see how
it is :
class MainPriority{
public static void main(String main[]){
System.out.println("Main priority is
:"+Thread.currentThread().getPriority());
}
}
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How does enum work in java?
What does the “static” keyword mean? Can you override private or static method in java?
What is the difference between stringbuffer and stringbuilder?
Differences between external iteration and internal iteration?
Explain the difference between an Interface and an Abstract class?
What is the nested interface?
Explain the transient field modifier?
What are the 6 boolean operators?
which pattern is default in scanner package?
What is continuity of a function?
What is command line used for?
Can we serialize static variables in java?
What is a boolean flag in java?
What is the significance of java packages?
State some advantages of java?