DipIETE – ET/CS (NEW SCHEME) -  Code: DE53/DC53

 

Subject: COMPUTER FUNDAMENTALS & C PROGRAMMING

Flowchart: Alternate Process: JUNE 2010
 


Time: 3 Hours                                                                                                     Max. Marks: 100

 

 

NOTE: There are 9 Questions in all.

·      Question 1 is compulsory and carries 20 marks. Answer to Q.1 must be written in the space provided for it in the answer book supplied and nowhere else.

·      Out of the remaining EIGHT Questions answer any FIVE Questions, selecting TWO questions from part A and THREE questions from part B. Each question carries 16 marks.

·      Any required data not explicitly given, may be suitably assumed and stated.

 

 

Q.1       Choose the correct or the best alternative in the following:                                  (210)

       

             a.  ASCII code use ______ bits per character.

 

                  (A) 6                                                    (B) 10

                  (C) 8                                                    (D) 12

 

             b. OCR stands for

 

                  (A) Open Character Reader                 (B) Optical Character Recognition

                  (C) Output Computer Reader               (D) None of the above

 

             c.  Who developed the C language?

 

                  (A) Ken thompson                                (B) Bjarne strou strup

                  (C) Dennis Ritchie                                (D) Kernighan

 

             d.  The number of bitwise operators in C is

 

                  (A) 4                                                    (B) 5

                  (C) 6                                                    (D) 7

 

             e.  What format is used to print a character with the prints function?

 

                  (A)%5                                                  (B) %C

                  (C) %Char                                           (D) % 1C

 

             f.   Identify the wrong construction

                 

                  (A) for (expr1;expr2;)                           (B) for (expr1;expr3)

                  (C) for (;expr;)                                     (D) for (;;expr3)

 

             g. Indentify the correct declaration

 

                  (A)int a[10] [10];                                  (B) int a[10,10];

                  (C)int a (10) (10);                                 (D) int a (10,10);

 

             h.  The parameters in a function call are

                                                                                                                                                                       

(A)  Actual parameters                          (B) formal parameters

                  (C) dummy parameters                         (D) optional

 

             i.   Indentify the correct declaration of pointer P1,P2

 

                  (A) int P1,P2                                        (B) int *P1,P2

                  (C) int P1,*P2;                                     (D) int *P1,*P2

 

             j.   If fopen ( ) fails , it return

 

                  (A)-1                                                   (B) NULL

                  (C) 1                                                    (D) the filepointer                                                 

            

 

PART A

Answer any TWO questions. Each question carries 16 marks.

 

 

 

  Q.2     a.   Draw the block of a computer. Explain the function of each of the blocks.           (8)

                  

             b.   Convert the following numbers into binary numbers.                                            (4)

                  

                   (i) 

                   (ii)

 

             c.   Convert binary number into hexadecimal number                   (2)

 

             d.   What is the purpose of using a parity check bit?                                                  (2)

 

  Q.3     a.   What is the advantage of inkjet printer compared to dot matrix printer?  What is its disadvantage?                                                              (4)

            

             b.   What is a speech output unit? What are its applications?                                     (4)

            

             c.   What is an assembly language for a computer? What are the main disadvantages of an assembly language?                                                           (4)

 

             d.   What is an operating system? What are the main functions of operating system?                  (4)

 

  Q.4     a.   What is a microprocessor? Explain the internal structure of a microprocessor                                  (6)

             b.   Differentiate between RAM and ROM (3)

 

             c.   What is an intranet? How is it different from internet?                                          (3)

 

             d.   Write a short note on Word Wide Web.                                                             (4)

 

 

PART B

Answer any THREE questions. Each question carries 16 marks.

 

 

  Q.5     a.   State the features of ‘C’ language.  Also describe the process of creating and executing a C program under UNIX system.                                     (4)

 

             b.   What is a modulus operator? What are the restrictions of a modulus operator?                                (3)

 

             c.   Write a program to convert an alphabet from uppercase to lowercase                 (3)

 

             d.   Write is the syntax of scanf( )                                                                             (3)

 

 

             e.   What is the output of the following code? Main ()                                               (3)

                                   {

                                      int x = 20 , y = 35 ;

                                      X = y++ + x++;

                                      Y = ++y + ++x ;

                                      printf (“%d  %d \ n”, X , Y);

                                     }

 

  Q.6     a.   Write a program using if else to check whether an integer is odd or even.            (4)

 

             b.   Give the equivalent while structure and do while structure for the following loop structure                (4)

                            for (i = 0; i< 10; i++)

                              {

                                 printf (“% d \ n” , i);

                               }

             c.   What is the difference between break and continue?                                           (4)

 

             d.   What are to be replaced in ??? to get the sum of the series

                   sum(x) = 1+ (1+2) + (1+2+3) +…+ (1+2+3+4+….+x) in the following code

                         sum (int x)

                             {

                              int i, term =1 , s = 1 ;

                              for (i=2 ; i< = ??? ; i++)

                                  {

                                    ???

                                     s + = term

                                   }

                                   return s ;

                                  }

 

  Q.7     a.   Define an array. How are arrays declared?                                                         (4)

 

             b.   Write a program to reverse a string using the .                                    (6)

 

             c.   Describe the limitations of using getchar and scanf for reading string?                (3)

 

             d.   What will be the output of the following segment?                                               (3)

                   char s1[] = “New Delhi”;

                   char s2[] = “Bangalore”;

                   strcpy(s1, s2, s3);

                   printf(“%s, s1);

 

 

  Q.8     a.   Distinguish between the following                                                                       (6)

 

                   (i)  Formal and actual arguments

                   (ii) Function definition and Function declaration

 

             b.   Write a program to find the factorial of the given number using recursion.             (8)

 

             c.   What is the purpose of main( ) function (2)

 

  Q.9     a.   What is an array of pointer ? How is an array of pointer declared.                       (3)

 

             b.   Write a program using pointers to compute the sum of all elements store in an array            (6)

 

             c.   What is a file? How is fopen( ) used?   (5)

 

             d.   Describe the use and limitations of the function getc and putc.                            (2)