Answer Posted / manoj kumar verma allahabad(ba
Abstract class shows kins of relationship.it is the impure
abstract.Abstract class can have method with body or
without. Abstract class can not be instantiated.e.g. Object
nahi ban sakta abstract class ka.
for example :-
abstract class Shape
{
abstract void area(); // No body compulsory to be
overriding
void show()
{
System.out.println("Shape is the show");
}
}
class circle extends Shape
{
void area()
{
}
void show()
{
System.out.println("Show the circle");
}
}
class Testabstract
{
public static void main(String ar[])
{
circle c1=new Shape(); // error object of
abstract class cannot be made
circle c2=new circle();
c2.area();
c1.show();
}
}
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
what is the diff bw sql direct and jdbc update can't we do select and updating operation in sql direct
Delta 5 weight scale not connect with oracle application what i can do?
how do we provide security for web services
how CLR identify vb file?
In mainframe SDSF, Can we copy the list of jobs currently executing in SDSF in to a seperate DATASET...?
what is the software to run the GSM gate opener program
hi viewers, tell me,what is scripting and programming, define and difference...pls
what are the missinschema properties and should we pass primary key in select command
could u please also write an example of a code that involves instances from an abstract class just as u did for interfaces because u said it could also work which i really doubt. thanks
Q1.Write a C program which asks the user for a number between 1 to 9 and shows the number. If the user inputs a number out of the specified range, the program should show an error and prompt the user for a valid input.
If u need any fake experience certificate in software side, contact me at: vikramyadhav@gmail.com
is it acceptable if we declare multiple exceptions in same overridden method.
what is meant by life cycle of a business
if 2 is passed as an argument to the method,void GC.Collect then what would be the result?
when a query is made on Logical file in DB2/400, will the records satisfying select/omit criterion be fetched from all members of physical file or only the member with same name as physical file?