Question
The following Java code attempts to demonstrate multiple inheritance, which is not directly supported for classes in Java. How can similar functionality be achieved using interfaces? class A { void methodA() { System.out.println("Method A"); } } class B { void methodB() { System.out.println("Method B"); } } // class C extends A, B { } // Problematic: Multiple inheritance not allowed public class Main { public static void main(String[] args) { // C obj = new C(); } }
More IT Operating System Questions
- The structure of an artificial 'neural network' in machine learning is primarily inspired by which of the following?
- Which of the following statements accurately describes hard computing?
- Consider the following Python code: def mystery(a, b): if a == 0: return b else: return mystery(b % a, a...
- In threat modeling, what does STRIDE stand for (one of the categories)? Pick the item that is NOT part of STRIDE.
- The Fibonacci sequence (F(n) = F(n-1) + F(n-2)) is a classic example demonstrating the benefits of Dynamic Programming. Without DP, a naive recursive solut...
- A cache miss occurs :
- Which of the following is a challenge in machine translation?
- Web Pages can be created using :
- Backtracking problem is seen in :
- A /26 subnet is divided into equal /28 subnets. How many /28 subnets are created?
Hey! Ask a query
Please enter email id
The email must be a valid email address.
Please enter Mobile Number
Please enter valid Mobile Number
Please enter your Doubt
Think You're Ready for RBI Grade B?
RBI Grade B 2026 Phase 1 Memory Based Paper
- 200 Questions with Detailed Solutions
- Section-wise Coverage (GA, English, Quant & Reasoning)