Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Filter
Profile
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
Answers by Oaesp
0
votes
1
GATE CSE 2002 | Question: 2.10
Consider the following algorithm for searching for a given number $x$ in an unsorted array $A[1..n]$ having $n$ distinct values: Choose an $i$ at random from $1..n$ If $A[i] = x$, then Stop else Goto 1; Assuming that $x$ is present in $A$, what is the expected number of comparisons made by the algorithm before it terminates? $n$ $n-1$ $2n$ $\frac{n}{2}$
Consider the following algorithm for searching for a given number $x$ in an unsorted array $A[1..n]$ having $n$ distinct values:Choose an $i$ at random from $1..n$If $A[i...
22.3k
views
answered
Aug 10, 2022
Algorithms
gatecse-2002
searching
normal
+
–
2
votes
2
GATE IT 2005 | Question: 1
A bag contains $10$ blue marbles, $20$ green marbles and $30$ red marbles. A marble is drawn from the bag, its colour recorded and it is put back in the bag. This process is repeated $3$ ... $\left(\dfrac{1}{6}\right)$ $\left(\dfrac{1}{4}\right)$ $\left(\dfrac{1}{3}\right)$
A bag contains $10$ blue marbles, $20$ green marbles and $30$ red marbles. A marble is drawn from the bag, its colour recorded and it is put back in the bag. This process...
8.2k
views
answered
Jun 27, 2022
Probability
gateit-2005
probability
normal
+
–
0
votes
3
GATE IT 2005 | Question: 36
Let $P(x)$ and $Q(x)$ ...
Let $P(x)$ and $Q(x)$ be arbitrary predicates. Which of the following statements is always TRUE?$\left(\left(\forall x \left(P\left(x\right) \vee Q\left(x\right)\right)\r...
14.8k
views
answered
Nov 26, 2021
Mathematical Logic
gateit-2005
mathematical-logic
first-order-logic
normal
+
–
0
votes
4
GATE CSE 1999 | Question: 22-a
Consider the set of relations EMP (Employee-no. Dept-no, Employee-name, Salary) DEPT (Dept-no. Dept-name, Location) Write an SQL query to: Find all employees names who work in departments located at ‘Calcutta’ and whose salary is greater than Rs.50,000. Calculate, for each department number, the number of employees with a salary greater than Rs. 1,00,000.
Consider the set of relationsEMP (Employee-no. Dept-no, Employee-name, Salary)DEPT (Dept-no. Dept-name, Location)Write an SQL query to:Find all employees names who work i...
12.4k
views
answered
Nov 11, 2021
Databases
gate1999
databases
sql
easy
descriptive
+
–
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register