Important Questions [4]
- The following function task() is a part of some class. Assume ‘m’ and ‘n’ are positive integers greater than 0. Answer the questions given below along with dry / run working.
- Assertion: Recursive data structure follows the LIFO principle. Reason: Execution of recursive code follows the concepts of data structure Queue.
- The following function is a part of some class: int jolly(int[] x, int n, int m) { if (n<0) return m; else if(n<x.length) m=(x[n]>m)?x[n]:m; return jolly(x, --n, m); } What will be the
- Design a class DeciHex to accept a positive integer in decimal number system from the user and display its hexadecimal equivalent. Example 1: Decimal number= 25 Hexadecimal equivalent= 19
