VTU First Year Engineering (C Cycle) (Semester 1)
Programming in C and Data Structures
May 2014
Total marks: --
Total time: --
INSTRUCTIONS
(1) Assume appropriate data and state your reasons
(2) Marks are given to the right of every question
(3) Draw neat diagrams wherever necessary


Choose the correct answer for the following :-
1 (a) (i) A computer converts data into this _____
(A) information
(B) charts
(C) software
(D) input or output
1 M
1 (a) (ii) A device that holds a disk is called
(A) drive
(B) RAM
(C) ROM
(D) memory
1 M
1 (a) (iii) The terms dots per inch (dpi) refers to
(A) printer resolution
(B) printer speed
(C) printer output
(D) printer size
1 M
1 (a) (iv) The earliest computer were ______ systems.
(A) digital
(B) paper
(C) analog
(D) slide rule
1 M
1 (b) Differentiate between system software and application software.
6 M
1 (c) Explain with example, different type of printers.
10 M

Choose the correct answer for the following :-
2 (a) (i) A list of command choice in an OS is called
(A) command line
(B) check box
(C) drop down list
(D) menu
1 M
2 (a) (ii) _____ is one of the benefits uing network.
(A) File security
(B) Peripheral sharing
(C) Protection from virus
(D) Folder creation
1 M
2 (a) (iii) FTP sites are often called
(A) channels
(B) archives
(C) groups
(D) domain
1 M
2 (a) (iv) DOS and Linux are examples of _____ interface.
(A) old fashion
(B) GUI
(C) command line
(D) parallel
1 M
2 (b) Explain in detail, various types of network topologies.
10 M
2 (c) Define the following -
(i) Thrashing
(B) Buffering
(C) Spooling
6 M

Choose the correct answer for the following :-
3 (a) (i) Which of the following is a character constant?
(A) 'C'
(B) "c"
(C) "b"
(D) "?"
1 M
3 (a) (ii) Which field specification is used to refer short int?
(A) %c
(B) %d
(C) %fd
(D) %hd
1 M
3 (a) (iii) A nibble is _____
(A) 4 bits
(B) 8 bits
(C) 16 bits
(D) 32 bits
1 M
3 (a) (iv) Identify formatted console input function.
(A) getchar ()
(B) gets()
(C) scanf()
(D) fgets()
1 M
3 (b) Explain the structure of 'C' program.
6 M
3 (c) What are the different types of inputs and output functions?
10 M

Choose the correct answer for the following :-
4 (a) (i) A _____ is name give to the memory location where data can be stored, accessed or manipulated.
(A) string
(B) keyword
(C) reserved word
(D) variable
1 M
4 (a) (ii) The _____ data type does not occupy any space in the memory.
(A) long int
(B) float
(C) void
(D) double
1 M
4 (a) (iii) An operator which acts on 3 operands
(A) Unary operator
(B) Key operator
(C) Binary operator
(D) Ternary operator
1 M
4 (a) (iv) what is the output of the following code ?
main ()
{printf("%d", 'A');}
(A) 65
(B) A
(C) 65.5
(D) Error
1 M
4 (b) Evaluate the expressions where a=8, b=15, c=4
(i) 2×((a%5)×(4+(b-3)/(c+2)))
(ii) 100/20 <=10-5+100%10-20==5>=1!=20
6 M
4 (c) Write a C program to find and output all the roots of a quadratic equation for non zero coeficients.
10 M

Choose the correct answer for the following :-
5 (a) (i) The default return type of function is
(A) int
(B) float
(C) char
(D) void
1 M
5 (a) (ii) Which is the user defined function?
(A) main ()
(B) sqrt()
(C) clrscr ()
(D) gets()
1 M
5 (a) (iii) A f unction that calls itself is knowns as _____
(A) recursive function
(B) itegrative function
(C) main function
(D) none of these
1 M
5 (a) (iv) Parameters passed as argument to the function call are called as
(A) actual parametes
(B) formal parameters
(C) no parameters
(D) none of these
1 M
5 (b) Design and develop a function rightrot (x, n) in C that returns the value of the integer x roated to the right by n bit positions as an unsigned integer. Invoke the function from the main with different values for x and n and print the results with suitable headings.
8 M
5 (c) How are functions categorized based on the value returned by the function and parameter accepted ?
8 M

Chooese the correct answer for the following :-
6 (a) (i) Each case statement in switch is seperated by
(A) break
(B) continue
(C) exit
(D) goto
1 M
6 (a) (ii) Several statement grouped together in braces is called
(A) compound
(B) equivalent
(C) complex
(D) simple
1 M
6 (a) (iii) In C language "x?y:z" is equivalent to
(A) if(x==0)y; else z;
(B) if(x==1)z; else y;
(C) if(x==0)y;z;
(D) if(x==1)y; else z;
1 M
6 (a) (iv) How many times is the following loop executed
for (i=0; i<=5; i++)
{printf("Hello");}
(A) 1
(B) 6
(C) zero
(D) infinite
1 M
6 (b) Write a C program to find the sum of N natural numbers.
8 M
6 (c) What is the purpose of a switch case statement? Explain with syntax.
8 M

Choose the correct answer for the following :-
7 (a) (i) The number of element in arraynA[3][4] is
(A) 8
(B) 12
(C) 16
(D) none of these
1 M
7 (a) (ii) If A[4] is declaration, them the first and last array index will be
(A) 1,4
(B) 0,3
(C) 3,0
(D) none of these
1 M
7 (a) (iii) A function that is used to string copy is
(A) strcopy()
(B) strcpy()
(C) copystring()
(D) concat()
1 M
7 (a) (iv) Given A[3][2]={1, 2, 3, 4, 5, 6}; the element in 3rd row 2nd col is
(A) 3
(B) 4
(C) 6
(D) 2
1 M
7 (b) Explain initialization and declaration of 2D array.
8 M
7 (c) Write a C program to input N integers in a single dimensional array and sort them in ascending order using Bubble sort.
8 M

Choose the correct answer for the following :-
8 (a) (i) _____ Execution of instruction in a computer system is referred to as parallel computing.
(A) Serial
(B) Sequential
(C) Accurate
(D) Simultaneous
1 M
8 (a) (ii) Open Mp stands for
(A) Open multi-parallelism
(B) Organized multi-programming
(C) Open multi-processing
(D) Organized multi-parallelism
1 M
8 (a) (iii) An example of environment variable in open MP is
(A) OMP_thread_limit
(B) OMP_init_lock
(C) OMP_thread_ref
(D) OMP_get_byname
1 M
8 (a) (iv) Which of the following can be used as a resource in parallel computing?
(A) A single computer with multiple processors.
(B) Networks of computers
(C) A combination of the above.
(D) All of these
1 M
8 (b) What are threads? Give the advatages and disadvantages of multiple threads.
8 M
8 (c) Design and develop a parallel program in C to determine and print prime numbers which are less than 100 making use of the algorithm of Sieve of Eratosthenes.
8 M



More question papers from Programming in C and Data Structures
SPONSORED ADVERTISEMENTS