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
we have syntax like for(int var : arrayName) this syntax is to find whether a number is in the array or not.but i want to know how to find that number's location.
What does i ++ mean in Java?
How do you control extraneous variables?
What is instance synchronization?
What is function declaration?
What is the purpose of static methods and variables?
Explain public static void main(string args[]) in java.
What is the exact difference in between Unicast and Multicast object? Where will it be used?
What will happen if a thrown exception is not handled?
What is object class in java?
What is yield () in java?
Is oracle java 11 free?
What are different data structures in java?
What is a lightweight component?
Which is better stringbuffer or stringbuilder?