Question
The sum of the monthly incomes of βAβ, βBβ and
βCβ is Rs. 40000 which is 4 times the monthly income of βCβ. If βAβ spends 30% of his income while βBβ spends 80% of his income and the sum of their savings is Rs. 18000, then find the savings of βAβ.Solution
Monthly income of βCβ = 40000/4 = Rs. 10000 Let the monthly income of βAβ be Rs. x Therefore, monthly income of βBβ = Rs. (30000 β x) According to the question, 0.70x + 0.20(30000 β x) = 18000 Or, 0.5x = 12000 x = 24000 Or, savings of βAβ = 0.7x = Rs. 16800
Which algorithm is used for computing Max-Flow in a network?
Given the following code snippet, which operation is performed on the binary tree to produce the output: 4, 2, 5, 1, 3 ?
class Node {Β Β Β Β Β in...Which data structure is most suitable for implementing a priority queue with logarithmic time complexity for insertion and deletion?
Tarjanβs algorithm is used to find:
In C++, which access specifier makes members accessible only from within the class itself and from friend functions/classes?
What is the worst-case time complexity for inserting an element into a hash table that uses separate chaining for collision resolution?
In a graph, what is the maximum number of edges in a simple undirected graph with 'n' vertices?
Time complexity of heap sort is:
Which of the following is true about triggers in a relational database?
What is the primary purpose of an abstract class?