1
GATE CSE 2021 Set 2
Numerical
+1
-0

Consider a complete binary tree with 7 nodes. Let A denote the set of first 3 elements obtained by performing Breadth-First Search (BFS) starting from the root. Let B denote the set of first 3 elements obtained by performing Depth-First Search (DFS) starting from the root.

The value of |A - B| is _______

Your input ____
2
GATE CSE 2021 Set 2
Numerical
+1
-0
A data file consisting of 1,50,000 student-records is stored on a hard disk with block size of 4096 bytes. The data file is sorted on the primary key RollNo. The size of a record pointer for this disk is 7 bytes. Each student-record has a candidate key attribute called ANum of size 12 bytes. Suppose an index file with records consisting of two fields, ANum value and the record pointer to the corresponding student record, is built and stored on the same disk. Assume that the records of data file and index file are not split across disk blocks. The number of blocks in the index file is _______
Your input ____
3
GATE CSE 2021 Set 2
MCQ (Single Correct Answer)
+2
-0.66

The relation scheme given below is used to store information about the employees of a company, where empId is the key and deptId indicates the department to which the employee is assigned. Each employee is assigned to exactly one department.

emp(empId, name, gender, salary, deptId)

Consider the following SQL query:

select deptId, count(⋆)

from emp

where gender = "female" and salary > (select avg(salary) from emp)

group by deptId;

The above query gives, for each department in the company, the number of female employees whose salary is greater than the average salary of

A
female employees in the department.
B
employees in the department.
C
employees in the company.
D
female employees in the company.
4
GATE CSE 2021 Set 2
MCQ (Single Correct Answer)
+1
-0.33

Consider the following statements S1 and S2 about the relational data model:

S1: A relation scheme can have at most one foreign key.

S2: A foreign key in a relation scheme R cannot be used to refer to tuples of R.

Which one of the following choices is correct? 

A
S1 is true and S2 is false.  
B
Both S1 and S2 are true.  
C
Both S1 and S2 are false.  
D
S1 is false and S2 is true. 
EXAM MAP
Medical
NEETAIIMS
Graduate Aptitude Test in Engineering
GATE CSEGATE ECEGATE EEGATE MEGATE CEGATE PIGATE IN
Civil Services
UPSC Civil Service
Defence
NDA
Staff Selection Commission
SSC CGL Tier I
CBSE
Class 12