Company: Qualcomm
Difficulty: medium
In a logistics management system, the class Truck inherits from Vehicle. This setup allows Truck to access shared properties and behaviors such as startEngine() and stopEngine() that exist in Vehicle. What does this relationship between Truck and Vehicle best represent in Object-Oriented Programming? Reusability of data members Parent-child hierarchy between classes Independent relationship between classes Creation of new data types Which one of the given options is true regarding Peterson's solution? Peterson's solution is a hardware-based solution to the entry section problem. Peterson's solution is a hardware-based solution to the critical section problem. Peterson's solution is a software-based solution to the entry section problem. Peterson's solution is a software-based solution to the critical section problem. What will be the return value on calling the function func(5)? int func(int x) { if (x == 0) return (1); return func(x - 1) + x; } 22 11 16 10 What will be the output of t