0% found this document useful (0 votes)
176 views5 pages

Technical Questions

The document contains 25 technical questions related to computer science topics like algorithms, data structures, databases, operating systems and computer networks. The questions are multiple choice or short answer types and cover topics like complexity classes, file operations, process creation, database normalization, SQL queries, microprocessor architecture, C programming, transactions, relations, and more.

Uploaded by

ankitamaheshwari
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
176 views5 pages

Technical Questions

The document contains 25 technical questions related to computer science topics like algorithms, data structures, databases, operating systems and computer networks. The questions are multiple choice or short answer types and cover topics like complexity classes, file operations, process creation, database normalization, SQL queries, microprocessor architecture, C programming, transactions, relations, and more.

Uploaded by

ankitamaheshwari
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

TECHNICAL

Date: 07th Sept 2013 Time Duration: 30 min

Ques1: Although the understanding of the precise relationship between P and NP is woefully incomplete, which of the following is the most likely representation of the complexity classes?

-NP P = NP = Co-NP (a)

Co-NP

NP Co-NP P (b)

NP

NP = Co-NP P (c) Co-NP P= NP Co-NP (d) NP

Ques 2: What does the following segment of code do? fprintf(fp, Copying!); a) It writes Copying! into the file pointed by fp b) It reads Copying! from the file and prints on display c) It writes as well as reads Copying! to and from the file and prints it d) None of the mentioned Ques 3: Mark the correct option(s) a) b) c) d) Trigraphs are not recognized in SQL statements. The precompiler recognizes the seven trigraphs within host variable declarations. ??? is also a trigraph sequence printf(Any questions???/n); will be translated as follows : printf(Any questions?\n); Find the error/output : void main() { int a = 1, b=2, c=3; char d = 0; if(a,b,c,d) { printf("EXAM"); }

Ques 4:

a) b) c) d)

} Error in line 5 : if(a,b,c,d) No Error, No output EXAM 49

Ques 5: How many processes are created in this snippet? main() { Fork(); Fork() && fork () || fork (); Fork (); } a. 15 b. 19 c. 21 d. 27 e. 31

Ques 6: #include <stdio.h> int main() { FILE *fp; char c; int n = 0; fp = fopen("newfile1.txt", "r"); while (!feof(fp)) { c = getc(fp); putc(c, stdout); } } a) Compilation error b) Prints to the screen content of newfile1.txt completely c) Prints to the screen some contents of newfile1.txt d) None of the mentioned Ques 7: Comment on the following two operations? 1 int *a[] = {{1, 2, 3}, {1, 2, 3, 4}}; 2 int b[4][4] = {{1, 2, 3}, {1, 2, 3, 4}}; a) 1 will work, 2 will not b) 1 and 2, both will work c) 1 wont work, 2 will work d) Neither of them will work

Ques 8: Write ahead logging is a way : a) to ensure atomicity b) to keep data consistent c) that records data on stable storage d) All of these Ques 9: In a system that does not support swapping, a) the compiler normally binds symbolic addresses (variables) to relocatable addresses b) the compiler normally binds symbolic addresses to physical addresses c) the loader binds relocatable addresses to physical addresses d) binding of symbolic addresses to physical addresses normally takes place during execution Ques 10: Each connection arriving at multi threaded servers via network is generally : a) is directly put into the blocking queue b) is wrapped as a task and passed on to a thread pool c) is kept in a normal queue and then sent to the blocking queue from where it is dequeued d) None of these Ques 11: Mark all the correct ones. Shell script is preferable to other forms of programming because it a) executes faster b) enhances portability c) occupies less space d) makes programming task easier Ques 12: The given FSM is a : 1/0, 0/1 Mealey machine Moore machine Kleene machine None of the mentioned Ques 13: n distinct 3-digit numbers are sorted using Radix sort method. What is the maximum no of queue operations performed for the same? a. 2n b. 3n c. 6n d. n Ques 14: Given a relation R with four attributes ABCD. For the given FD : F ={ AB C, AB D, C A, D B } (a) Identify the candidate key(s) for R.

(b) Identify the best normal form that R satisfies (1NF, 2NF, 3NF, or BCNF). (c) If R is not in BCNF, decompose it into a set of BCNF relations that preserve the dependencies. Ques 15: Which of the following is the fastest way to find the number of rows in a table? a) b) c) d) count(1) count(*) count(rowid) count (ALL)

Ques 16: A Priority-Queue is implemented as a Max-Heap. Initially, it has 5 elements. The level order traversal of the heap is : 10, 8, 5, 3, 2 Two new elements 1 and 7 are inserted in the heap in that order. The level order traversal of the heap after the insertion of the elements is: (a) 10, 8, 7, 5, 3, 2, 1 (b) 10, 8, 7, 2, 3, 1, 5 (c) 10, 8, 7, 1, 2, 3, 5 (d) 10, 8, 7, 3, 2, 1, 5 Ques 17: Conditional results after execution of an instruction in a micro processor is stored in a) register b) accumulator c) flag register d) flag register part of PSW Ques 18: Among the following declarations in C, which is (are) the correct one(s): a) b) c) d) short const register i = 10; static volatile const int i = 10; unsigned auto long register i = 10; signed extern float i = 10.0;

Ques 19: Which three commands cause a transaction to end? (Choose three) a) ALTER b) GRANT c) DELETE d) INSERT e) UPDATE f) ROLLBACK Ques 20: Consider a relation R= {(a,2,3,4,5), (2,a,3,4,5), (a,2,3,6,5), (a,2,3,6,6)} with five attributes ABCDE. State whether it violates (a) the FD BC D and (b) the MVD BC D:

Ques 21: A device driver can be thought of as a translator. Its input consists of _____ commands and output consists of _______ instructions. a) high level, low level b) low level, high level c) complex, simple d) Both a and c Ques 22: With n relations, there are ____________ different join orders. Ques 23: Write an SQL query to delete duplicate rows from the relation Ques 24: Write an SQL query to determine the 5th largest value of an attribute. Ques 25: Write a program to checking whether a number is Power of 2 or not, using bitwise operators! Question : What is the purpose of using header nodes in the linked?

You might also like