Is it possible to create object with out its default
constructor? if possible how? else not possible? justify
Answer Posted / ravi
class C
{
void show()
{
System.out.println("hi");
}
public static void main(String args[])
{
C c=new C();
c.show();
}
}
we can create object if we don't write the constructor try
execute the above code and see the result; THANK u
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Explain the scope of a variable.
Can you make a constructor final?
Tell me the Importent classes in net package?
When will you define a method as static?
What are constants?
Does java have extension methods?
Why vector class is used?
Difference between method overloading and method overriding in java ?
Why constructor has no return type?
State some advantages of java?
What is the difference between a break statement and a continue statement?
How do you remove duplicates in java?
Does java vector allow null?
What are the basic concepts of OOPS in java?
What are the 8 primitive data types in java?