Topic 12 - List ADT Flashcards

1
Q

Can an interface implement another interface? Extended another interface?

A

No. Yes.

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

Is multiple inheritance legal? Ie. a class extends two classes? can an interface extend multiple interfaces?

A

No. Yes.

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

Can a class implement two or more interfaces?

A

Yes.

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

What type of list collections are there?

A

1) Ordered lists
2) Unordered lists
3) Indexed lists

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

The Comparable Interface: How do we implement this part?

A

Declare a variable that is of type Comparable
Cast the variable of type T to the variable type Comparable:
“Comparable tempt = (Comparable)element;”

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