Abstract Classes Flashcards

1
Q

True or False

An abstract method can be defined inside a concrete class without implications

A

False. If an abstract method is defined inside a concrete class, the class must be declared abstract

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Can abstract classes define concrete constructors?

A

Yes. However, abstract constructors are illegal

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Can abstract classes be instantiated?

A

No. However, they can define concrete constructors

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Can abstract classes declare instance variables?

A

Yes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Can abstract classes define concrete methods?

A

Yes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Can an abstract class define its own abstract contructor?

A

No. Abstract constructors are illegal

How well did you know this?
1
Not at all
2
3
4
5
Perfectly