‹ Back to the paper
State any one use of interfaces in Java.
Answer
Answer
AIInterfaces are used in Java to achieve multiple inheritance: a class can implement more than one interface, inheriting abstract behaviour from multiple sources without the ambiguity that arises from extending multiple classes.
From ISC 2024 Computer Science Paper 1, question 1(vii).