Wednesday, 26 October 2016

Cocubes Preassess computer fundamentals questions-1

1. Consider following given code and predict its output.
           main()
          {
                    int num[ ] = {1,4,8,12,16};
                          int *a,*b;
                          int i;
                          a=num;
                           b=num+2;
                            i=*a+1;
                           printf("%d,%d,%d\n",i,*a,*b);
          }
ops:  A. 2,1,8   B.  4,1,8      C.  4,4,8    D.   2,4,8

Ans: 2,1,8

2. Suppose f(A,B)=A'+B. Simplified expression for function f(f(x+y,y),z) is :
ops :    A. x'+z   B. xyz   C. xy'+z   D.  None of the mention options

Answer:  xy'+z

3. The number of control lines for a 8-to-1 multiplexer is:      
ops :  A. 3   B. 4   C. 2   D. 5

Ans: 3

4. Stack is useful for implementing:
A. recursion   B.  depth first search   C. both (A) & (B)    D. breadth first search

Ans: Both(A) & (B)

5. HUB is a _______ device and switch is a ________ device.
ops : A. multicast,unicast   B. multicast,broadcast        C. broadcast,unicast  D. broadcast,multicast

Ans: C. broadcast,unicast

6.what is the binary equivalent of the number 368?  
a.111100000
b.111010000
c.101110000
d.110110000

Ans: c.101110000

7.what will be the output of the follwing loop?
#include<stdio.h>
main()
{
While(Printf(“%d”,    printf(“az”)))
Printf(“by”);
}
a.none of these    b.it gives syntax error      c.it will print azbyazbyazbyazby…      d.it will print azbybyby…

Ans: c.it will print azbyazbyazbyazby…    

8.which of the following combinations of the variables x,y,z makes the variable ‘a’ get the value 4
In the following expression?
A=(x>y)?((x>z)?x:z):( (y>z)?y:z)
a.x=3;y=4;z=2       b.x=6;y=5;z=3        c.x=5;y=4;y=5      d.x=6;y=3;z=5

Ans:  a.x=3;y=4;z=2    

9.press the enter key in all of the circumstances except…………
a.to insert a blank line into a document    b.to begin a new paragraph
c.when the insertion point reaches the right margin   d.in response to certain word commands

Ans: c.when the insertion point reaches the right margin



10.what will be the output of the following c code?
#include<stdio.h>
Int main()
{
Int a =0,b=1,c=2;
*(  (  a+1==1) ?  &b  :  &a)= a?   b  :  c;
Printf(“%d, %d, %d \n” a , b, c ;)
return 0;
}
Options: a. 0,1,2   b. 2,2,2   c. 0,2,2   d. 1,1,2
Ans: Not Available, if you solve it please comment the answer below in comment sections :) thanks


11.The following fragment of c program will print?
char c[  ] = “DATA1234”
char * P = C;
printf (“%S” P+P[3]-P[1]);

a.DATA1234    b.234    c.1234    d.A1234

Ans: DATA1234  

12. What is Extended ASCII table
Ans: The Extended ASCII Character Set also consists of 128 decimal numbers and ranges from 128 through 255 (using the full 8-bits of the byte)

13. Mozilla Firefox is a/an
Ans: web browser.

14.  ------------ helps in capturing the data and entering into computer system.
Ans: Input devices

15. Secret key encryption is also know as ----------
Ans: Private Key Encryption or Symmetric Key Encryption.

16. A class defined with in another class is named as
a)inheritance     b)nested    c)container class    d)encapsulation

Ans: b)nested  

18. what  is simplest way of implementing a graph in c or c++
         a)associative lists     b)both adjacency matrix and assosiative list             c)none of these
       d)adjacency matrix

Ans: Not Available, if you solve it please comment the answer below in comment sections :) thanks

19. Which of the OSI model is responsible for compression and decompression
          a)presentation layer     b)transport layer    c)application layer              d)session layer

Ans: presentation layer  

20. Upon mixing two independent one-many relationships__________dependency arises.
          a)transitive            b)multivalued             c)functional              d)partial

Ans: Multivalued

21. If L is left node, M is middle node, R is right node then an L-M-R traversal can be termed as_____
           A) post order      b) in order                 c) preorder               d) this is invalid order

Ans: In order

22. Which of the OSI model layer is also known as end-to-end layer
           a) session layer              b) presentation layer   c) Transport layer               d) Network layer

Ans: Transport Layer

23.  Which of  the OSI model layer is responsible for both encryption and decryption
          a) Presentation layer               b)Network layer               c) session layer              d) transport layer

Ans: Presentation Layer

24.  Identify the point that is not true with respect to stack
           a) not possible to insert or remove elements anywhere except the top of stack
           b) Stack supports LIFO(last in first out) for deleting elements
           c) None of these
           d) stack is dynamic set where elements are removed in reverse order of insertion
 
Ans: Not Available, if you solve it please comment the answer below in comment sections :) thanks

25. When word flag a possible spelling or grammar error, it also changes mark on the spelling and grammar status icon to _____________
         a) red x                 b) red check mark                c) green check mark                d) green x

Ans: Red X

26. Identify the point that is NOT true with respect to a queue?
a.deletion from the queue happens only at the tail of the queue.
b.Queue supports FIFO(First In First Out)order of removal of elements.
c.none of these
d.Insertion in queue happens only at the head of the queue.

Ans: Not Available, if you solve it please comment the answer below in comment sections :) thanks

28. Periodic collection of all the free memory space to form contiguous block of free space by an operating system is called:
a.garbage collection                 b.Dynamic memory allocation    c.collison               d.concatenation

Ans: Not Available, if you solve it please comment the answer below in comment sections :) thanks


29. In C programming array index starts from:  
a.0 or 1        b.0          c.1           d.none of these

Ans: 0

30. java source code is compiled into_________.
a.byte code       b.word code      c.bit code     d.objective code

Ans: Byte Code

31. the output quality of a printer is measured by:
a.Dots printed per unit time     b.Dot per centimetre    c.Dot per sq.inch    d.Dot per inch

Ans: Dot per sq.inch

32.The number of full and half adders required to add 16-bit numbers is:
a.16 half-adders,0 full-adders
b.8 half –adders,8 full-adders
c.4 half-adders,12 full-adders
d.1 half-adder,15 full-adders

Ans: d.1 half-adder,15 full-adders

33. To select a group of words,________.
a.right-click the first and last characters of the group to be selected
b.double-click anywhere within the group to be selected
c.click the group button on the formatting toolbar
d.drag the mouse pointer through the characters to be selected

Ans: d.drag the mouse pointer through the characters to be selected

34.what will be the output of following C code?
                1.  struct abc
                2.  {
                3.            int b=6;
                4.            char c;
                5.  }
                6.  structure;
                7.  int main()
                8.  {
                9.            int i=sizeof(structure);
                10.          printf(“%d”,i);
                11. }

a.4          b.1          c.2          d.6

Ans: 6

35. There is a question, I did not remember but answer is 3NF
Ans: Not Available, if you solve it please comment the answer below in comment sections :) thanks
Related Pages

No comments:

Post a Comment