Question
Seven people, A, B, C, D, E, F, and G, are sitting in a
straight line, facing north. Only two people sit to the right of E. F sits third to the left of E. Only four people sit between F and G. Only two people sit to the left of C. B sits to the immediate left of F. D is NOT an immediate neighbour of C. How many people sit between B and C?Solution
1. Arrangement: - Positions: [1, 2, 3, 4, 5, 6, 7] - E is at position 5 (since only two sit to its right). - F is at position 2 (third to E's left). - G must be at position 7 (four people between F and G). - C is at position 3 (only two to its left). - B is at position 1 (immediate left of F). - D cannot be at position 4 (adjacent to C), so D is at position 6. 2. Between B (1) and C (3): Only person at position 2 (F).
Which of the following is a critical concern for securing critical infrastructure?
Output of below code
public class Prg {
public static void main(String args[]){
System.out.print("A" + "B" + 'A');
}
...The Bellman-Ford algorithm executes relaxation steps how many times for a graph with V vertices?
In a Min-Heap, the root node is:
Which algorithm is best suited for finding a Hamiltonian cycle in an undirected graph?
In Database Management Systems, what is the primary purpose of normalization?
Which of the following operations on a data structure refers to the removal of an element from the front of a queue?
The Master Theorem gives time complexity for recurrences of the form:
Which of the following problems cannot be solved using greedy algorithms for optimal result?
Which of the following SQL queries is used to remove a table from a database?