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


Please Help Members By Posting Answers For Below Questions

If a variable is declared as private, where may the variable be accessed?

553


What are some characteristics of interference class?

518


Do I need java for windows 10?

551


What is Session reduplication and how its done?

1567


How do you read a char in java?

463






What is the r character?

588


What is treemap in java?

552


What is t in generics in java?

561


Explain exception chaining in java?

611


How many types of variables are there?

674


Can you achieve runtime polymorphism by data members?

589


What does replaceall do in java?

488


What are different types of inner classes ?

562


Why do I need to declare the type of a variable in java?

566


Are arrays classes in java?

535