Friday 28 February 2014

UGC NET for Computer Science 2013 December Paper 2: Questions & Answer Key

Q1. When data and acknowledgement are sent in the same frame, this is called as
(A) Piggy packing
(B) Piggy backing
(C) Back packing
(D) Good packing
ANS-(B)

2. Encryption and Decryption is the responsibility of Layer.
(A) Physical
(B) Network
(C) Application
(D) Datalink
ANS-(C)

3. An analog signal carries 4 bits in each signal unit. If 1000 signal units are sent per second, then baud rate and bit rate of the signal are and
(A) 4000 bauds \ sec & 1000 bps
(B) 2000 bauds \ sec & 1000 bps
(C) 1000 bauds \ sec & 500 bps
(D) 1000 bauds \ sec & 4000 bps
ANS-(D)

4. The VLF and LF bauds use propagation for communication.
(A) Ground         
(B) Sky
(C) Line of sight  
(D) Space
ANS-(A)

5. Using the RSA public key crypto system, if p = 13, q = 31 and d = 7, then the value of e is
(A) 101 
(B) 103
(C) 105
(D) 107
ANS-(B)

6. FAN IN of a component A is defined as
(A) Number of components that can call or pass control to component A.
(B) Number of components that are called by component A.
(C) Number of components related to component A.
(D) Number of components dependent on component A.
ANS-(A)

7. The relationship of data elements in a module is called
(A) Coupling
(B) Modularity
(C) Cohesion
(D) Granularity
ANS-(C)

8. Software Configuration Management is the discipline for systematically controlling
(A) the changes due to the evolution of work products as the project proceeds.
(B) the changes due to defects (bugs) being found and then fixed.
(C) the changes due to requirement changes
(D) all of the above
ANS-(D)

9. Which one of the following is not a step of requirement engineering ?
(A) Requirement elicitation
(B) Requirement analysts
(C) Requirement design
(D) Requirement documentation
ANS-(C)

10. Testing of software with actual data and in actual environment is called
(A) Alpha testing
(B) Beta testing
(C) Regression testing
(D) None of the above
ANS-(B)

11. The student marks should not be greater than 100. This is
(A) Integrity constraint(B) Referential constraint
(C) Over-defined constraint
(D) Feasible constraint
ANS-(A)

12. GO  BOTTOM  and  SKTP-3 commands are given one after another in a database file of 30 records. It shifts the control to
(A) 28th record     
(B) 27th record
(C) 3rd record      
(D) 4th record
ANS-(A)

13. An ER Model includes
I.   An ER diagram portraying entity types.
II.  Attributes for each entity type
III. Relationships among entity types.
IV.  Semantic integrity constraints that reflects the business rules about data not captured in the ER diagram.
(A) I, II, III & IV  
(B) I&IV
(C) I, II & IV       
(D) I & III
ANS-(A)

14. Based on the cardinality ratio and participation associated with a relationship type, choose either the Foreign Key Design, the Cross Referencing Design or Mutual Referencing Design.
(A) Entity   
(B) Constraints
(C) Rules   
(D) Keys
ANS-(B)

15. Data Integrity control uses  
(A) Upper and lower limits on numeric data.
(B) Passwords to prohibit unauthorised access to files.
(C) Data dictionary to keep the data
(D) Data dictionary to find last access of data
ANS-(B)

16. What does the following declaration mean ?
int (*ptr) [10];
(A) ptr is an array of pointers of 10 integers.
(B) ptr is a pointer to an array of 10 integers.
(C) ptr is an array of 10 integers.
(D) none of the above.
ANS-(B)

17. Which of the following has compilation error in C ?
(A) int n = 32 ;
(B) char ch = 65 ;
(C) float f= (float) 3.2;
(D) none of the above
ANS-(D)

18. Which of the following operators can not be overloaded in C+ + ?
(A) *   
(B) + =
(C) = =    
(D) ::
ANS-(D)

19. allows to create classes which are derived from other classes, so that they automatically include some of its "parent's" members, plus its own members.
(A) Overloading
(B) Inheritance
(C) Polymorphism
(D) Encapsulation
ANS-(B)

20. The correct way to round off a floating number x to an integer value is
(A) y = (int)(x + 0.5)
(B) y = int (x + 0.5)
(C) y = (int)x+ 0.5
(D) y = (int)((int)x + 0.5)
ANS-(A)

21. What is the value of the postfix expression ?
a b c d + - * (where a = 8, b = 4, c = 2 and d = 5)
(A) -3/8   
(B) -8/3
(C) 24
(D) -24
ANS-(D)

22. If the queue is implemented with a linked list, keeping track of a front pointer and a rear pointer, which of these pointers will change during an insertion into a non-empty queue ?
(A) Neither of the pointers change
(B) Only front pointer changes
(C) Only rear pointer changes
(D) Both of the pointers changes
ANS-(C)

23. _________ is often used to prove the correctness of a recursive function.
(A) Diagonaliization
(B) Communitivity
(C) Mathematical Induction
(D) Matrix Multiplication
ANS-(C)

24. For any B-tree of minimum degree t > 2, every node other than the root must have atleast _________ keys and every   node can have at, most ________ keys.
(A) t-1,2t+1
(B) t+1,2t+1
(C) t-1,2t-1
(D) t+1,2t-1
ANS-(C)

25. Given two sorted list of size 'm' and 'n' respectively. The number of comparison needed in the worst case
by the merge sort algorithm will be
(A) m x n
(B) max (m, n)
(C) min (m, n)
(D) m + n - 1
ANS-(D)

26. Given the following statements :
S1 :  SLR uses follow information to guide reductions. In case of LR and LALR parsers, the look-aheads are associated with the items and they make use of the left context available to the parser.
S2 : LR grammar is a larger subclass of context free grammar as compared to that SLR and LALR grammars.
Which of the following is true ?
(A) S1 is not correct and S2 is not correct.
(B) S1 is not correct and S2 is correct.
(C) S1 is correct and S2 is not correct.
(D) S1 is correct and S2 is correct.
ANS-(D)

27. The context  free grammar for the language
      L={anbm|n≤m+3,n≥0.m≥0}is
(A)   S→aaaA; A→aAb|B, B→Bb | λ, 
(B)   S → aaaA|λ, A -> aAb | B, B→ Bb|λ
(C)   S→aaaA | aa A |λ , A -> aAb | B|λ, B→ Bb|λ
(D)   S→aaaA | aa A | aA |λ , A → aAb | B, B→ Bb | λ
ANS-(D)

28. Given the following statements :
S1 :    If L is a regular language then the language {uv | u Є L, v Є LR} is also regular.
S2 :    L = {wwR }is regular language.
Which of the following is true ?
(A) S1 is not correct and S2 is not correct.
(B) S1 is not correct and S2 is correct.
(C) S1 is correct and S2 is not correct.
(D) S1 is correct and S2 is correct.
ANS-(C)

29. The process of assigning load addresses to the various parts of the program and adjusting the code and data in the program to reflect the assigned addresses is called    ____________
(A) Symbol resolution
(B) Parsing
(C) Assembly
(D) Relocation
ANS-(D)

30. Which of the following derivations does a top-down parser use while parsing an input string ? The input is scanned from left to right.
(A) Leftmost derivation
(B) Leftmost derivation traced out in reverse
(C) Rightmost derivation traced out in reverse
(D) Rightmost derivation
ANS-(A)

31. The dual of a Boolean expression is obtained by interchanging
(A) Boolean sums and Boolean products
(B) Boolean sums and Boolean products or interchanging 0's and 1 's
(C) Boolean sums and Boolean products and interchanging 0's & 1's
(D) Interchanging 0's and 1's
ANS-(C)

32. Given that (292) 10 = (1204)x in some number system x. The base x of that number system is
(A) 2
(B) 8
(C) 10
(D) None of the above
ANS-(D)

32. Given that (292) 10 = (1204)x in some number system x. The base x of that number system is
(A) 2
(B) 8
(C) 10
(D) None of the above
ANS-(D)

34. Let P(m, n) be the statement
    "m divides n" where the universe of discourse for both the variables is the set of
     positive integer.Determine the truth values of each of the following propositions:
    I:  VmVnP(m,n),
    II. Ǝm Vn P(m, n)

(A) Both I and II are true
(B) Both I and II are false
(C) I - false & II - true
(D) I - true & II - false
ANS-(C)

35. Big - 0 estimate for
    f(x) = (x + 1) log(x^2 + 1) + 3x^2 is given as
(A) O(xlogx)
(B) O(x^2)
(C) O(x^3)
(D) O(x^2 logx)
ANS-(B)

36. How many edges are there in a forest of t-trees containing a total of n vertices ?
(A) n+1
(B) n-t
(C) n*t
(D) nt
ANS-(B)

37. Let f and g be the functions from the set of integers to the set integers defined by
f(x) = 2x + 3 and g(x) = 3x + 2
Then the composition of f and g and g and f is given as
(A) 6x + 7,  6x + 11
(B) 6x + 11, 6x + 7
(C) 5x + 5, 5x + 5
(D) None of the above
ANS-(A)

Composition of f and g is gof = g(f(x))

38. If n and r are non-negative integers and n > r, then p(n + 1, r) equals to
(A) P(n,r)(n + 1) / (n + 1 - r)
(B) P(n,r)(n+1) / (n - 1 + r)
(C) p(n,r)(n-l) / (n + 1 - r)
(D) p(n,r)(n + l) / (n + 1 + r)
ANS-(A)

39. A graph is non-planar if and only if it contains a subgraph homomorphic to
(A) K3,2 or K5      
(B) K3,3 and K6
(C) K3,3 or K5    
(D) K2,3 and K5
ANS-(C)

40. Which of the following statements are true ?
I.   A circuit that adds two bits, producing a sum bit and a carry bit is called half adder.
II.  A circuit that adds two bits, producing a sum bit and a carry bit is called full adder.
III. A circuit that adds two bits and a carry bit producing a sum bit and a carry bit is called full adder.
IV.  A device that accepts the value of a Boolean variable as input and produces its complement is called an inverter.
(A) I & II   
(B) II & III
(C) I,II,III   
(D) I,III & IV
ANS-(D)

41 Active X controls are Pentium binary programs that can be embedded in ____________
(A) Word pages
(B) URL pages
(C) Script pages
(D) Web pages
ANS-(D)

42.    Match the following :
List-I                                                       List - II
a. Wireless Application Environment          i.   HTTP      
b. Wireless Transaction Protocol               ii.   IP
c. Wireless Datagram Protocol                  iii    Scripts
d. Wireless                                     iv.   UDP
Codes :      
     a     b     c    d
(A) ii    iv     i    iii
(B) iv    iii     ii    i
(C) iv    iii     i    ii
(D) iii    i     iv    ii
ANS-(D)

43. Which of the following is widely used inside the telephone system for long-haul data traffic ?
(A) ISDN
(B) ATM
(C) Frame Relay
(D) ISTN
ANS-(B)

44. The document standards for EDI were first developed by large business house during the 1970s and are now under the control of the following standard organisation :
(A) ISO
(B) ANSI
(C) ITU-T
(D) IEEE
ANS-(B)

45. Electronic Data Interchange Software consists of the following four layers :
(A) Business application, Internal format conversion, Network translator, EDI envelope
(B) Business application, Internal format conversion, EDI translator, EDI envelope
(C) Application layer, Transport layer, EDI translator, EDI envelope
(D) Application layer, Transport layer, IP layer, EDI envelope
ANS-(B)

46. Consider a preemptive priority based scheduling algorithm based on dynamically changing priority.
Larger priority number implies higher priority. When the process is waiting for CPU in the ready queue
(but not yet started execution), its priority changes at a rate a = 2. When it starts running, its priority changes at a rate b = 1. All the processes are assigned priority value 0 when they enter ready queue. Assume that the following processes want to execute :
Process      Arrival  Service
ID          Time    Time
PI             0          4
P2            1          1
P3            2          2
P4            3          1
The time quantum q = 1. When two processes want to join ready queue simultaneously, the process which has not executed recently is given priority. The finish time of processes PI, P2, P3 and P4 will respectively be
(A) 4, 5, 7 and 8
(B) 8, 2, 7 and 5
(C) 2, 5, 7 and 8
(D) 8, 2, 5 and 7
ANS-(B)

47. The virtual address generated by a CPU is 32 bits. The Translation Look-aside Buffer (TLB) can hold
total 64 page table entries and a 4-way set associative (i.e. with 4- cache lines in the set). The page size
is 4 KB. The minimum size of TLB tag is
(A) 12 bits
(B) 15 bits
(C) 16 bits
(D) 20 bits
ANS-(C)

48. Consider a disk queue with request for input/output to block on cylinders
98, 183, 37, 122, 14, 124, 65, 67
in that order. Assume that disk head is initially positioned at cylinder 53 and moving towards cylinder number 0. The total number of head movements using Shortest Seek Time First (SSTF) and SCAN algorithms are respectively
(A) 236 and 252 cylinders
(B) 640 and 236 cylinders
(C) 235 and 640 cylinders
(D) 235 and 252 cylinders
ANS-(A)

If we solve it we get SSTF- 236 but when SCAN doesn't move 252 cylinder.

49. How much space will be required to store the bit map of a 1.3 GB disk with 512 bytes block size ?
(A) 332.8 KB
(B) 83.6 KB
(C) 266.2 KB
(D) 256.6 KB
ANS-(A)

50. Linux operating system uses
(A) Affinity Scheduling
(B) Fair Preemptive Scheduling
(C) Hand Shaking
(D) Highest Penalty Ratio Next
ANS-(B)

UGC NET December 2013 Answer Key of Computer Science and Applications (Code 87): Paper 3: Questions & Answer Key

1. If the primal Linear Programming problem has unbounded solution,then it’s dual problem will have
       (A) feasible solution
       (B)  alternative solution
       (C)  no feasible solution at all
       (D) no bounded solution at all
   
      ANS (C)
2. Given the problem to maximize f(x),X=(x1,x2,...xn) subject to m number of inequity constraints
gi(x)<=bi,i=1,2.....,m
Including the non-negativity constraints x>= 0.
Which one of the following conditions is a Kuhn-Tucker necessary condition for a local maxima at x?

(A) L(X,λ,S) / Xj  = 0,j = 1,2,...m

(B) λ[gi(X)-bi]=0,j = 1,2,...m

(C) gi(X)<=bi, i = 1,2...m

(D) All of the above

 Ans (D)

3. The following linear programming  problem has

Max  Z = x1 + x2

Subject to
x1 - x2 >= 0
3x1 - x2 <= -3
x1 >= 0,x2 >= 0

(A) Feasible solution
(B) No feasible solution
(C) Unbounded solution
(D) Single point as solution
Ans (B)

4. Given a flow graph with 10 nodes. 13 edges and one connected components, the number of regions and the number of predicate(decision) nodes in the flow graph will be
(A) 4,5
(B) 5,4
(C) 3,1
(D) 13,8
ANS-(B)

 5. Function points can be calculated by
(A) UFP*CAF
(B) UFP*FAC
(C) UFP*Cost
(D) UFP*Productivity
ANS-(A)
UFP is Unadjusted Function Point
CAF is Complixity Adjustment Factor Function Point FP = UFP*CAF
 
6. Match the following:
         List-I                               List-II
a. Data coupling    i. Module A and Module B have shared data
b. Stampcoupling    ii. Dependency between modules is based on the fact they communicate by only passing of data.
c. Common coupling    iii. When complete data structure is passed from one module to another.
d. Content    coupling    iv.When the control is passed from one  module to the middle of another.

Codes:
    
    a    b    c    d
(A)    iii    ii    i    iv
(B)    ii    iii    i    iv
(C)    ii    iii    iv    i
(D)    iii    ii    iv    i
ANS-(B)

7. A process which defines a series of tasks that have the following four primary objectives is known as
          1. to identify all items that collectively defines the software configuration.
          2. to manage changes to one or more of these items.
          3. to facilitate the construction of different versions of an application.
          4. to ensure that software quality is maintained as the configuration evolves over time.
(A) Software Quality Management Process
(B) Software Configuration Management Process
(C) Software Version Management Process
(D) Software Change Management Process
ANS-(B)

8. One weakness of boundary value analysis and equivalent partitioning is
(A) they are not effective.
(B) they do not explore combinations of input circumstances.
(C) they explore combinations of input circumstances
(D) none of the above
ANS-(B)

9. Which one of the following is not a software myth?
(A) Once we write the program and get it to work, our job is done.
(B) Project requirement continually change, but change can be easily accommodated because software is flexible.
(C) If we get behind schedule, we can add more programmers and catch up.
(D) If an  organization does not understand how to control software project internally, it will invariably struggle when it outsources software projects.
ANS-(D)

10. Match the following with respect to relationship between objects and classes:
         List-I                               List-II
a. State diagram    i. Useful for both abstract modeling and for designing actual program.
b. Object diagram    ii. Describes object classes.
c. Class diagram    iii. Useful for documenting test cases.
d. Instance diagram    iv. Describing the behavior of a single class of object.

Codes:
    a    b    c    d
(A)    iv    i    ii    iii
(B)    ii    iii    iv    i
(C)    iii    iv    ii    i
(D)    ii    iv    i    iii
ANS-(A)

11. Match the following style rules for reusability:
         List-I                               List-II
a. Keep methods coherent    i. Write a method to get the last element of a list.
b. Keep methods small        ii. Maintain parallel structure when possible.
c. Keep methods consistent    iii. Breaking a method into smaller parts.
d. Provide uniform coverage    iv. Perform a single function or a group of closely related function.
Codes:
      a    b    c    d
(A)    iv    iii    ii    i
(B)    ii    i    iv    iii
(C)    iii    iv    ii    i
(D)    ii    iii    iv    i
ANS-(A)

12. Which is the protocol for performing RPCs between applications in a language and system independent way?
(A) Hyper Text Transmission Protocol (HTTP)
(B) Simple Network Management Protocol (SNMP)
(C) Simple Object Access Protocol (SOAP)
(D) Simple Mail Transfer Protocol (SMTP)
ANS-(C)


13. The document that is used by XSLT to indicate, how to transform the element of the XML document to another format is
(A) HTML page
(B) DOC type procedure
(C) Style sheet
(D) Store procedure
ANS-(C)


14. Which of the following concepts means adding new concept to a program as it runs?
(A) Data hiding
(B) Dynamic loading
(C) Dynamic typing
(D) Dynamic binding
ANS-(B)


15. Which of the following correctly describes overloading of functions?
(A) Virtual polymorphism
(B) Transient polymorphism
(C) Ad-hoc polymorphism
(D) Pseudo polymorphism
ANS-(C)


16. Match the following with respect to programming languages:
         List-I                                   List-II
a. Structured Language                i. JAVA
b. Non-structured Language            ii. BASIC
c. Object oriented Programming Language        iii. PASCAL
d. Interpreted Programming Language        iv. FORTRAN

Codes:
      a    b    c    d
(A)    iii    iv    i    ii
(B)    iv    iii    ii    i
(C)    ii    iv    i    iii
(D)    ii    iii    iv    i
ANS-(A)

 17. The compiler converts all operands upto the type of the largest operand is called
(A) Type Promotion
(B) Type Evaluation
(C) Type Conversion
(D) Type Declaration
ANS-(A)

 18. C++ actually support the following two complete dynamic system
(A) one defined by C++ and the other not defined by C.
(B) one defined by C and one specific to C++.
(C) Both are specific to C++
(D) Both of them are improvements of C.
ANS-(B)

 This question is incomplete. Here word "allocation" is missing.

19. Important advantage of using new and delete operation in C++ is
(A) Allocation of memory
(B) Frees the memory previously allocated
(C) Initialization of memory easily
(D) Allocation of memory and frees the memory previously allocated.
ANS- (D)


20. Match the following control strategies of prolog:
         List-I                               List-II
a. Forward movement        i. Variable can be done with a constant, another variable or a function
b. Unification            ii. The entire conjunctive goal is executed.
c. Deep backtracking        iii. Previous sub goal to find alternative solutions.
d. Shallow backtracking        iv. Choose sub goal with possible unifier.
Codes:
      a    b    c    d
(A)    iv    i    ii    iii
(B)    ii    iv    i    iii
(C)    iii    i    iv    ii
(D)    ii    iii    iv    i
ANS-(A)


21. Given the following statements.
S1 : The grammars S -> asb | bsa | ss | a and S -> asb | bsa | a are not  equivalent
S2:  The grammars S -> ss | sss | asb | bsa | λ and S-> ss | asb | bsa | λ are equvalent

Which one of the following is true?

(A) S1 is correct and S2 is not correct.

(B) Both S1 & S2 are correct

(C) S1 is not correct & S2 is correct

(D) Both S1 & S2 are not correct
Ans (B)

 22. What are the final value of Q1 and Q0 after 4 clock cycles, if initial values are 00 in the sequential circuit shown below
(A) 11
(B) 10
(C) 01
(D) 00
 ANS-(D)

23. High level knowledge which relates to the use of sentences in different contexts and how the context affect the meaning of the sentences?
(A) Morphological
(B) Syntactic
(C) Semantic
(D) Pragmatic
ANS-(D)

24. The objective of ___________ procedure is to discover at least one ________ that causes two literals to match
(A) unification, validation
(B) unification, substitution
(C) substitution, unification
(D) minimax, maximax
ANS-(B)

25. If h* represents an estimate of the cost of getting from the current node N to the goal and h represents actual cost of getting from current node to the goal node, then A* algorithm gives an optimal solution if
(A) h* us equal to h
(B) h* overestimates h
(C) h* underestimates h
(D) none of these
ANS- (C)

26. The mean-end analysis process centers around the detection of difference between the current state and the goal state. Once such a difference is isolated, an operator that can reduce the difference must be found. But perhaps that operator can not be applied to the current state. So a sub-problem of getting to a state in which it can be applied is set up. The kind of backward chaining in which operators are selected and then sub goals are set up to established the precondition of operators is called
(A) backward planning
(B) goal stack planning
(C) operator subgoaling
(D) operator overloading
ANS-(C)

27. In alpha-beta pruning, ______ is used to cut off the search at maximizing level only and _______ is used to cut off the search at minimizing level only.
(A) alpha,beta
(B) beta,alpha
(C) alpha,alpha
(D) beta,beta
ANS-(B)

28. If A and B are two fuzzy sets with membership functions
µA(X) ={0.2,0.5,0.6,0.1,0.9}
µB(X)={0.1,0.5,0.2,0.7,0.8}
then the value of µA^B will be

(A) {0.2,0.5,0.6,0.7,0.9}
(B) {0.2,0.5,0.2,0.1,0.8}
(C) {0.1,0.5,0.6,0.1,0.8}
(D) {0.1,0.5,0.2,0.1,0.9}
Ans (D)

29. The height of h(A) of a fuzzy set A is defined as
h(A) = sup A(X)
The the fuzzy set A is called normal when
(A) h(A) = 0
(B) h(A) < 0
(C) h(A) = 1
(D) h(A) < 1
Ans (C)

30. An artificial neurons received n inputs x1,x2,...,xn with weights w1,w2,...,wn attached to the input links. The weighted  sum _______ is computed to be passed on to a non-linear filter φ called activation function to release the output.
(A) Σ wi
(B) Σ xi
(C) Σ wi + Σ xi
(D) Σ wi . Σ xi
Ans (D)

31. Consider the formula in image processing
Rd = 1 - (1/Cr)  where Cr = N1 / N2
Cr is called as compression ration N1 and N2 denotes the number of information
Carrying units into two data sets that represents the same information. In this situation Rd is called as relative ______ of the first data set
(A) Data compression
(B) Data redundancy
(C) Data Relation
(D)  Data representation
Ans (D)

32. Find the false statement:
(A) In Modern Cryptography symmetric key algorithms use same key
both for  Encryption and Decryption.
(B) The Symmetric cipher DES(Data Encryption Standard) was widely
used in the industry for security product.
(C) The AES(Advanced Encryption Standard) cryptosystem allows variable
Key lengths of size 56 bits and 124 bits.
(D)Public key algorithms use two different keys for Encryption and Decryption.
ANS-(C)

33.  The message 11001001 is to be transmitted using the CRC
Polynomial x3+1 to protect it from errors. The message that should be
Transmitted is
(A) 110010011001
(B) 11001001
(C) 110010011001001
(D) 11001001011
ANS-(D)

34. _____________ comparisons are necessary in the worst case to
find both the maximum and minimum of n numbers.
(A) 2n-2
(B)  n + floor(lg n) - 2
(C)  floor(3n/2) - 2
(D)2 lg n – 2
ANS-(C)

35. Let A and B be two n x n matrices. The efficient algorithm to
Multiply the two matrices has the time complexity
     (A) O(n3)
     (B) O(n2.81)
     (C) O(n2.67)
     (D) O(n2)
ANS-(B)

36. The recurrence relation T(n)=mT(n/2)tan2  is satisfied by
(A) O(n2)
(B) O(nlg m)
(C) O(n2 lg n)
(D) O(n lg n)
ANS-(B)

This is wrong question.If in this question 'tan' is replaced by '+a'
then the solution is (B)


37. The longest common subsequence of the sequence
X=<A,B,C,B,D,A,B>  and  Y=<B,D,C,A,B,A> has length
(A) 2
(B)  3
(C)  4
(D) 5
ANS-(C)


38. Assuming there are n keys and each keys is in the range [0,m-1]
The run time of bucket sort is
(A) O(n)
(B) O(n lgn)
(C) O(n lgm)
(D) O(n+m)
ANS-(D)

39. A __________ complete subgraph and a________
subset of vertices of a graph G=(V,E) are a clique and a vertex
cover respectively.
(A) minimal,  maximal
(B)  minimal,  minimal
(C)  maximal,  maximal
(D) maximal, minimal
ANS-(D)

40. Pumping lemma of the context-free languages states:
Let L be an infinite context free language . Then there exist some positive integer m such that w ξ L with |w|>=m can be decomposed as
w=uv xy  Z with |vxy| ________________ and |vy| _______ such that uv2xy2 Z ξ L for all Z = 0,1,2,...

(A) <= m, <=1
(B) <=m, >= 1
(C) >=m, <=1
(D) >=m, >=1
Ans (B)


42. Given the following statements:
S1: Every context-sensitive language L is recursive.
S2: There exists a recursive language that is not context sensitive.
Which statement is correct?
(A) S1 is not correct and S2 is not correct.
(B)  S1 is not correct and S2 is correct.
(C)  S1 is correct and S2 is not correct.
(D) S1 is correct and S2 is correct.
ANS-(D)


42. Given the following statements:
S1: Every context-sensitive language L is recursive.
S2: There exists a recursive language that is not context sensitive.
Which statement is correct?
(A) S1 is not correct and S2 is not correct.
(B)  S1 is not correct and S2 is correct.
(C)  S1 is correct and S2 is not correct.
(D) S1 is correct and S2 is correct.
ANS-(D)

43. What is the bit rate for transmitting uncompressed 800x600 pixel color frames with 8 bits/pixel at 40 frames/second?
Ans. 153.6 Mbps

44. In IPv 4, the IP address 200.200.200.200 belongs to
(A) Class A
(B) Class B
(C) Class C
(D) Class D
ANS-(C)


45. Which layer of OSI reference model is responsible for decomposition of message and generation of sequence numbers to ensure correct re-composition from end to end the network?
(A) Physical
(B) Data-link
(C) Transport
(D) Application
ANS-(C)

46. A client-server system uses a satellite network, with the satellite at a height of 40,000 kms. What is the best-case delay in responses to a request? (Note that the speed of light in air is 3,00,000 km/second).
(A) 133.33 m sec
(B) 266.67 m sec
(C) 400.00 m sec
(D) 533.33 m sec
ANS-(D)

47. The start and stop bits are used in serial communication for
(A) error detection
(B) error correction
(C) synchronization
(D) slowing down the communication.
ANS-(C)

48. ______________ is a type of transmission impairment in which the signal looses strength due to the resistance of the transmission medium
(A) Attenuation
(B) Distortion
(C) Noise
(D) Decibel
ANS-(A)

49. Match the following:
         List-I                               List-II
a. Indexed Addressing    i. is not used when an operand is moved from memory into a register or from a register to memory.
b. Direct Addressing        ii. Memory address is computed by adding up two registers plus an (optional) offset.
c. Register Addressing        iii. Addressing memory by giving a register plus a content offset.
d. Base-Indexed Addressing    iv. can only be used to access global variables whose address is known at compile time.
Codes:
    a    b    c    d
(A)    ii    i    iv    Iii
(B)    ii    iv    i    Iii
(C)    iii    iv    i    ii
(D)    iii    i    iv    ii
ANS-(C)
 
50. Which of the following is a design criteria for instruction formats?
(A) The size of instructions
(B) The numbers of bits in the address fields
(C) The sufficient space in the instruction format to express all the operations desired.
(D) All of these
ANS-(D)

51. Synchronization is achieved by a timing device called a ________ which generates a periodic train of _________.
(A) clock generator, clock pulse
(B) master generator, clock pulse
(C) generator, clock
(D) master clock generator, clock pulse
ANS-(D)

52. Serial access memories are useful in applications where
(A) Data consists of numbers
(B) Short access time is required.
(C) Each stored word is processed differently.
(D) None of these
ANS-(D)

 53. What will be the output of the following logic diagram
(A) x OR y
(B) x AND y
(C) x NOR y
(D) x XNOR y
ANS-(C)

54. The essential difference between traps and interrupt is
(A) traps are asynchronous and interrupt are synchronous with the program
(B) traps are synchronous and interrupt are asynchronous with the program
(C) traps are synchronous and interrupt are asynchronous with the I/O devices.
(D) None of these.
ANS-(B)

55. Consider the following ER diagram
The minimum number of tables required to represents M,N,P,R1,R2 is
(A) 2
(B) 3
(C) 4
(D) 5
ANS-(A)

56. Consider the following schemas:
Branch = (Branch_name,  Assets, Branch_city)
Customer = (Customer-name, Bank-name,Customer-city)
Borrow = (Branch-name, loan-number, customer-name, Balance)
Deposit = (Branch-name, Account-number, Customer-name, Balance)
Using relational Algebra, the query that finds customers who have balance
More than 10,000 is ________
(A) πcustomer-name(σbalance > 10000(Deposit))
(B)  σcustomer-name(σbalance > 10000(Deposit))
(C) πcustomer-name(σbalance > 10000(Borrow))
(D)σcustomer-name(σbalance > 10000(Deposit))
ANS-(A)

57. Find the false statement:
(A) The relationship construct known as the weak relationship
 type was defined by Dey, Storey & Barron (1999).
(B) A weak relationship occurs when two relationship types are
linked by either Event-Precedent sequence or Condition-Precedent
sequence
(C) Conceptual model is not accurate representation of
"Universe of interest".
(D) Ternary, Quaternary and Quintary relationships are shown
through a series of application scenario's and vignette's
ANS-(C)

58. Consider the table
 Student(stuid, name, course, marks).
Which one of the following two queries is correct to find the
highest marks student in course 5?

Q.1. Select S.stuid
       From student S
       Where not exists
       (select * from student e where
        e course='5' and e marks >= s
       marks)
Q.2.  Select S.stu.id
       From student S
       Where s.marks > any
       (select distinct marks from
       student S where s.couse = 5)

(A) Q.1
(B) Q.2
(C) Both Q.1 and Q.2
(D) Neither Q.1 nor Q.2
ANS-(B)

59. Armstrong (1974) proposed systematic approach to derive
functional dependencies. Match the following w.r.t. functional dependencies.
Codes:
      a    b    c    d
(A)    iii    ii    iv    i
(B)    i    iii    iv    ii
(C)    ii    i    iii    iv
(D)    iv    iii    i    ii
ANS-(D)

60. Match the following
List I                                    List II
(a)  Secondary Index                (i) Functional dependency
     (b) Non-procedural Query       (ii) B-tree
     (c)  Closure set Attribute          (iii) Relational Algebraic Operation
     (d) Natural Join                        (iv) Domain Calculus
   
     Codes:
(a)        (b)       (c)     (d)
(A)      i        ii         iv      iii
(B)      ii         i         iv      iii
(C)       i        iii        iv       ii
(D)     ii        iv         i       iii
ANS-(D)


61. Which of the following is not true with respect to a trackball and/or  spaceball
I. A trackball is a two dimensional positioning device while as a spaceball provides six degree of freedom
II. Unlike the trackball a spaceball does not actually move.
III. A trackball is a three dimensional positioning device while as a spaceball provides six degree of freedom.
(A) I & II
(B)  II & III
(C)  II only
(D) III only
ANS-(D)


62. Which of the following statement(s) is(are) true?
I. Two successive translations are additive.
II. Two successive rotations are additive.
III. Two successive scaling operations multiplicative.
(A) I and II
(B)  I and III
(C)  II and III
(D) All of above.
ANS-(D)

 63. Given below are three basic rules:
      I. Squash and Stretch
     II. Slow-in and Slow out
    III. To stage the action properly

These rules are applied in case of
(A) Rendering
(B) Morphing
(C) Animation
(D) All of above
ANS-(C)

64. Which of the following points lies on the same side as the origin, with reference to the line
3x+7y=2 ?
(A) (3,0)
(B) (1,0)
(C) (0.5,0.5)
(D) (0.5,0)
ANS-(D)

Put the value of x and y in the equation 3x+7y
if 3x+7y <2 then it lies on the same side of origin
else if 3x+7y > 2 it does not lies on the same side of origin



 65. The transformation matrix required for conversion of CMY color model to RGB color model is given as
ANS- (C)

66. What step shall be required to rotate an object about the point P1 and its placement such that what was at P1 is now reduced and is at P2.
I. Translate P1 to origin
II. Scale as required
III. Rotate
IV. Translate to the final position P2.
(A) I,II and III
(B) II,III and IV
(C) I,III and IV
(D) All of the above
ANS-(D)

67. In Unix, how do you check that two given strings a and b are equal
(A) test $a -eq $b
(B) test $a -equal $b
(C) test $a=$b
(D) sh -C test $a==$b
ANS-(C)

68. In windows 2000 operating system all the processor-dependent code is isolated in a dynamic link library called
(A) NTFS file system
(B) Hardware Abstraction layer
(C) Microkernel
(D) Process Manager
ANS-(B)

69. To place a sound into a word document, following feature of windows is used
(A) Clip board
(B) Task switching
(C) C Win App
(D) OLE
ANS-(D)

70. Translation Look-aside Buffer(TLB) is
(A) a cache-memory in which item to be searched is compared
one-by-one with the keys.
(B) a cache-memory in which item to be searched is compared
with all the keys simultaneously.
(C) an associative memory in which item to be searched is compared
one-by-one with the keys.
(D) an associative memory in which item to be searched is compared
 with all the keys simultaneously.
ANS-(D)

71. Simplest way of deadlock recovery is
(A) Roll back
(B) Preempt resource
(C) Lock one of these processes
(D) Kill one of the processes
ANS-(D)

72. The directory structure used in Unix file system is called
(A) Hierarchical directory
(B) Tree structure directory
(C) Directed acyclic graph
(D) Graph structured directory
ANS-(C)

73. Which statement is not true about process 0 in the Unix operating system?
(A) Process 0 is called init process.
(B) Process 0 is not created by fork system call.
(C) After forking process 1, process 0 becomes swapper process.
(D) Process 0 is a special process created when system boots.
ANS-(A)

74. Which one of the following commands would return process_id of sleep command?
(A) Sleep 1 and echo $?
(B) Sleep 1 and echo $#
(C) Sleep 1 and echo $x
(D) Sleep 1 and echo $!
ANS-(D)

75. Possible thread states in Windows 2000 operating system include:
(A) Ready,running and waiting
(B) Ready, standby, running, waiting, transition and terminated.
(C) Ready, running, waiting, transition and terminated
(D) Standby, running, transition and terminated.
ANS-(B)

Monday 17 February 2014

DATABASE AND SQL

Basic Database concepts
Data:- Raw facts and figures which are useful to an organization. We cannot take decisions on the basis of data.
Information:- Well processed data is called information. We can take decisions on the basis of information
Field:- Set of characters that represents specific data element.
Record:-Collection of fields is called a record. A record can have fields of different data types.
File:- Collection of similar types of records is called a file.
Table:- Collection of rows and columns that contains useful data/information is called a table. A table generally refers to the passive entity which is kept in secondary storage device.
Relation:- Relation (collection of rows and columns) generally refers to an active entity on which we can perform various operations.
Database:- Collection of logically related data along with its description is termed as database.
Tuple:- A row in a relation is called a tuple.
Attribute:- A column in a relation is called an attribute. It is also termed as field or data item.
Degree:- Number of attributes in a relation is called degree of a relation.
Cardinality:-  Number of tuples in a relation is called cardinality of a relation.
Primary Key:-  Primary key is a key that can uniquely identifies the records/tuples in a relation. This key can never be duplicated and NULL.
Foreign Key:- Foreign Key is a key that is defined as a primary key in some other relation. This key is used to enforce referential integrity in RDBMS.
Candidate Key:- Set of all attributes which can serve as a primary key in a relation.
Alternate Key:-  All the candidate keys other than the primary keys of a relation are alternate keys fora relation.
DBA:- Data Base Administrator is a person (manager) that is responsible for defining the data base schema, setting security features in database, ensuring proper functioning of the data bases etc.
Structured Query Language:- SQL is a non procedural language that is used to create, manipulate and process the databases(relations).
Characteristics of SQL:-
1. It is very easy to learn and use.
2. Large volume of databases can be handled quite easily.
3. It is non procedural language. It means that we do not need to specify the procedures to
accomplish a task but just to give a command to perform the activity.
4. SQL can be linked to most of other high level languages that makes it first choice for the
database programmers.
Processing Capabilities of SQL
The following are the processing capabilities of SQL
1. Data Definition Language (DDL)
DDL contains commands that are used to create the tables, databases, indexes, views, sequences and synonyms etc.
e.g:
Create table, create view, create index, alter table etc.
2. Data Manipulation Language (DML)
DML contains command that can be used to manipulate the data base objects and to query the databases for information retrieval.
e.g : Select, Insert, Delete, Update etc.
3. View Definition:
DDL contains set of command to create a view of a relation.
e.g :create view
4. Data Control Language:
This language is used for controlling the access to the data. Various commands like GRANT, REVOKE etc are available in DCL.
5. Transaction Control Language (TCL):
TCL include commands to control the transactions in a data base system. The commonly used commands in TCL are COMMIT, ROLLBACK etc.
Data types of SQL:
Just like any other programming language, the facility of defining data of various types is available in
SQL also. Following are the most common data types of SQL.
1) NUMBER
2) CHAR
3) VARCHAR / VARCHAR2
4) DATE
5) LONG
6) RAW/LONG RAW
1.
NUMBER: Used to store a numeric value in a field/column. It may be decimal, integer or a real value. General syntax is
Number(n,d)
Where n specifies the number of digits and d specifies the number of digits to the right of the decimal point. e.g marks number(3) declares marks to be of type number with maximum value 999. pct number(5,2) declares pct to be of type number of 5 digits with two digits to the right of decimal point.
2.CHAR: Used to store character type data in a column. General syntax is
Char (size) where size represents the maximum number of characters in a column. The CHAR type data can hold at most 255 characters. e.g name  char(25) declares a data item name of type character of upto 25 size long.
3.VARCHAR/VARCHAR2:This data type is used to store variable length  alphanumeric data. General syntax is varchar(size) / varchar2(size) where size  represents the maximum number of characters in a column. The maximum  allowed size in this data type is 2000 characters. e.g address varchar(50); address is of type varchar of upto 50 characters long.
4. DATE: Date data type is used to store dates in columns. SQL supports the various date formats other that the standard DD-MON-YY. e.g dob date; declares dob to be of type date.
5.LONG: This data type is used to store variable length strings of upto 2 GB size.
e.gdescription long;
6.RAW/LONG RAW: To store binary data (images/pictures/animation/clips etc.) RAW or LONG RAW data type is used. A column LONG RAW type can hold upto 2 GB of binary data.e.g image raw(2000);
SQL Commands
a. CREATE TABLE Command:
Create table command is used to create a table in SQL. It is a DDL type of command. The general
syntax of creating a table is
Creating Tables
The syntax for creating a table is
create table <table> (
<column 1> <data type> [not null] [unique] [<column constraint>],
.........
<column n> <data type> [not null] [unique] [<column constraint>],
[<table constraint(s)>]
);
For each column, a name and a data type must be specified and the column name must be unique within the table definition. Column definitions are separated by comma. Uppercase and lowercase letters makes no difference in column names, the only place where upper and lower case letters matter are strings comparisons. A not null Constraint means that the column cannot have null value, that is a value needs to be supplied for that column. The keyword unique specifies that no two tuples can have the same attribute value for this column.
Operators in SQL:
The following are the commonly used operators in SQL
1. Arithmetic Operators
+, -, *, /
2. Relational Operators
=, <, >, <=, >=, <>
3. Logical Operators
OR, AND, NOT
Arithmetic operators are used to perform simple arithmetic operations.
Relational Operators are used when two values are to be compared and
Logical operators are used to connect search conditions in the WHERE Clause in SQL.
Constraints:
Constraints are the conditions that can be enforced on the attributes of a relation. The constraints come in play when ever we try to insert, delete or update a record in a relation.
1. NOT NULL
2. UNIQUE
3. PRIMARY KEY
4. FOREIGN KEY
5. CHECK
6. DEFAULT
Not null ensures that we cannot leave a column as null. That is a value has to be supplied for that column.
e.g
name varchar(25) not null;
Unique constraint means that the values under that column are always unique.
e.g
Roll_no number(3) unique;
Primary key constraint means that a column can not have duplicate values and not even a null value.
e.g.
Roll_no number(3) primary key;
The main difference between unique and primary key constraint is that a column specified as unique may have null value but primary key constraint does not allow null values in the column. Foreign key is used to enforce referential integrity and is declared as a primary key in some other table.
e.g cust_id varchar(5) references master(cust_id);
it declares cust_id column as a foreign key that refers to cust_id field of table master. That means we cannot insert that value in cust_id filed whose  corresponding value is not present in cust_id field of master table.
Check constraint limits the values that can be inserted into a column of a table.
e.g
marks number(3)
check(marks>=0);
The above statement declares marks to be of type number and while inserting or updating the value in marks it is ensured that its value is always greater than or equal to zero. Default constraint is used to specify a default value to a column of a table automatically. This default value will be used when user does not enter any value for that column.
e.g balance number(5) default = 0;
CREATE TABLE student ( Roll_no number(3) primary key, Name varchar(25)  not null, Class varchar(10), Marks number(3) check(marks>0), City varchar(25)  );
Data Modifications in SQL
After a table has been created using the create table command, tuples can be inserted into the table,or tuples can be deleted or modified.
INSERT Statement
The simplest way to insert a tuple into a table is to use the insert statement
insert into <table> [(<column i, . . . , column j>)] values (<value i, . . . , value j>);
INSERT INTO student VALUES(101,'Rohan','XI',400,'Jammu');
While inserting the record it should be checked that the values passed are of same data types as the
one which is specified for that particular column.
For inserting a row interactively (from keyboard) & operator can be used.
e.g
INSERT INTO student VALUES(&Roll_no‘,‘&Name‘,‘&Class‘,‘&Marks‘,‘&City‘);
In the above command the values for all the columns are read from keyboard and inserted into the
table student.
NOTE:- In SQL we can repeat or re-execute the last command typed at SQL prompt by typing
“/” key and pressing enter.
Roll_no Name Class Marks City
101 Rohan XI 400 Jammu
102 Aneeta Chopra XII 390 Udhampur
103 Pawan Kumar IX 298 Amritsar
104 Rohan IX 376 Jammu
105 Sanjay VII 240 Gurdaspur
113 Anju Mahajan VIII 432 Pathankot
Queries:
To retrieve information from a database we can query the databases. SQL SELECT statement is used to select rows and columns from a database/relation.
SELECT Command This command can perform selection as well as projection.
Selection:This capability of SQL can return you the tuples form a relation with all the attributes.
Projection:This is the capability of SQL to return only specific attributes in the relation.
SELECT * FROM student;
command will display all the tuples in the relation student
SELECT * FROM student WHERE Roll_no <=102;
The above command display only those records whose Roll_no less than or equal to 102.
Select command can also display specific attributes from a relation.
SELECT name, class FROM student;
The above command displays only name and class attributes from student table.
SELECT count(*) AS "Total Number of Records" FROM student;
Display the total number of records with title as "Total Number of Records" i.e an alias We can also use arithmetic operators in select statement, like
SELECT Roll_no, name, marks+20 FROM student;
SELECT name, (marks/500)*100 FROM student WHERE Roll_no > 103;
Eliminating Duplicate/Redundant data
DISTINCT keyword is used to restrict the duplicate rows from the results of a SELECT statement.
e.g. SELECT DISTINCT name FROM student;
The above command returns
Name
Rohan
Aneeta Chopra
Pawan Kumar
Conditions based on a range
SQL provides a BETWEEN operator that defines a range of values that the column value must fall for the condition to become true.
e.g.
SELECT Roll_no, name FROM student WHERE Roll_no BETWENN 100 AND 103;
The above command displays Roll_no and name of those students whose Roll_no lies in the range 100 to 103 (both 100 and 103 are included in the range).
Conditions based on a list To specify a list of values, IN operator is used. This operator select values that match any value in the given list.
e.g.
SELECT * FROM student WHERE city IN ( ̳Jammu‘,‘Amritsar‘,‘Gurdaspur‘);
The above command displays all those records whose city is either Jammu or Amritsar or Gurdaspur.
Conditions based on Pattern SQL provides two wild card characters that are used while comparing the strings with LIKE operator.
a.percent(%)
Matches any string
b.Underscore(_)
Matches any one character
e.g
SELECT Roll_no, name, city FROM student WHERE Roll_no LIKE "%3";
displays those records where last digit of Roll_no is 3 and may have any number of characters in
front.
e.g
SELECT Roll_no, name, city FROM student WHERE Roll_no LIKE "1_3";
displays those records whose Roll_no starts with 1 and second letter may be any letter but ends with digit 3.
ORDER BY Clause
ORDER BY clause is used to display the result of a query in a specific order(sorted order). The sorting can be done in ascending or in descending order. It should be kept in mind that the actual data in the database is not sorted but only the results of the query are displayed in sorted order.
e.g.
SELECT name, city FROM student ORDER BY name;
The above query returns name and city columns of table student sorted by name in increasing/ascending order.
e.g.
SELECT * FROM student ORDER BY city DESC;
It displays all the records of table student ordered by city in descending order.
Note:- If order is not specifies that by default the sorting will be performed in ascending order.
GROUP BY Clause
The GROUP BY clause can be used in a SELECT statement to collect data across multiple records and group the results by one or more columns.
The syntax for the GROUP BY clause is:
SELECT column1, column2, ... column_n, aggregate_function (expression)
FROM tables
WHERE conditions
GROUP BY column1, column2, ... column_n;
aggregate_function can be a function such as SUM, COUNT, MAX, MIN, AVG etc.
e.g
SELECT name, COUNT(*) as "Number of employees"
FROM student
WHERE marks>350
GROUP BY city;
HAVING Clause
The HAVING clause is used in combination with the GROUP BY clause. It can be used in a SELECT statement to filter the records that a GROUP BY returns.
The syntax for the HAVING clause is:
SELECT column1, column2, ... column_n, aggregate_function (expression)
FROM tables
WHERE predicates
GROUP BY column1, column2, ... column_n
HAVING condition1 ... condition_n;
e.g
SELECT SUM(marks) as "Total marks" FROM student GROUP BY department
HAVING SUM(sales) > 1000;
Note: select statement can contain only those attribute which are already present in the group by clause.
Functions available in SQL
SQL provide large collection of inbuilt functions also called library functions that can be used directly in SQL statements.
1. Mathematical functions
2. String functions
3. Date & Time functions
1. Mathematical functions
Some of the commonly used mathematical functions are sum() avg(), count(), min(), max() etc.
e.g. SELECT sum(marks) FROM student;
displays the sum of all the marks in the table student.
e.g.SELECT min(Roll_no), max(marks) FROM student;
displays smallest Roll_no and highest marks in the table student.
2. String functions
These functions are used to deal with the string type values like
ASCII, LOWEWR, UPPER, LEN, LEFT, RIGHT, TRIM, LTRIM, RTRIM etc.
ASCII : Returns the ASCII code value of a character(leftmost character of string).
Syntax: ASCII(character)
SELECT ASCII('a') returns 97
SELECT ASCII('A') returns 65
SELECT ASCII('1') returns 49
SELECT ASCII('ABC') returns 65
For Upper character 'A' to 'Z' ASCII value 65 to 90
For Lower character 'A' to 'Z' ASCII value 97 to 122
For digit '0' to '9' ASCII value 48 to 57
NOTE: If no table name is specified then SQL uses Dual table which is a dummy table used for
performing operations.
LOWER : Convert character strings data into lowercase.
Syntax: LOWER(string)
SELECT LOWER('STRING FUNCTION') returns string function
UPPER : Convert character strings data into Uppercase.
Syntax: UPPER(string)
SELECT UPPER('string function') returns STRING FUNCTION
LEN : Returns the length of the character string.
Syntax: LEN(string)
SELECT LEN('STRING FUNCTION') returns 15
REPLACE : Replaces all occurrences of the second string(string2) in the first string(string1) with a third string(string3).
Syntax: REPLACE('string1','string2','string3')
SELECT REPLACE('STRING FUNCTION','STRING','SQL') returns
SQL Function Returns NULL if any one of the arguments is NULL.
LEFT : Returns left part of a string with the specified number of characters counting from left.LEFT function is used to retrieve portions of the string.
Syntax: LEFT(string,integer) SELECT LEFT('STRING FUNCTION', 6) returns
STRING RIGHT : Returns right part of a string with the specified number of characters counting from right.RIGHT function is used to retrieve portions of the string.
Syntax: RIGHT(string,integer) SELECT RIGHT('STRING FUNCTION', 8) returns
FUNCTION LTRIM : Returns a string after removing leading blanks on Left side.(Remove left side space or blanks)
Syntax: LTRIM(string) SELECT LTRIM(' STRING FUNCTION') returns STRING FUNCTION
RTRIM : Returns a string after removing leading blanks on Right side.(Remove right side space or
blanks)
Syntax: RTRIM( string )
SELECT RTRIM('STRING FUNCTION ') returns STRING FUNCTION
REVERSE : Returns reverse of a input string.
Syntax: REVERSE(string)
SELECT REVERSE('STRING FUNCTION') returns NOITCNUF GNIRTS
REPLICATE : Repeats a input string for a specified number of times.
Syntax: REPLICATE (string, integer)
SELECT REPLICATE('FUNCTION', 3) returns
FUNCTIONFUNCTIONFUNCTION
SPACE : Returns a string of repeated spaces. The SPACE function is an equivalent of using REPLICATE function to repeat spaces.
Syntax: SPACE ( integer) (If integer is negative, a null string is returned.)
SELECT ('STRING') + SPACE(1) + ('FUNCTION') returns
STRING FUNCTION
SUBSTRING : Returns part of a given string.
SUBSTRING function retrieves a portion of the given string starting at the specified
character(startindex) to the number of characters specified(length).
Syntax: SUBSTRING (string,startindex,length)
SELECT SUBSTRING('STRING FUNCTION', 1, 6) returns STRING
SELECT SUBSTRING('STRING FUNCTION', 8, 8) returns FUNCTION
DELETE Command
To delete the record fro a table SQL provides a delete statement. General syntax is:-
DELETE FROM <table_name> [WHERE <condition>];
e.g. DELETE FROM student WHERE city =  ̳Jammu‘;
This command deletes all those records whose city is Jammu.
NOTE: It should be kept in mind that while comparing with the string type values lowercase and uppercase letters are treated as different. That is "Jammu‟ and "jammu‟ is different while comparing.
UPDATE Command
To update the data stored in the data base, UOPDATE command is used.
e. g. UPDATE student SET marks = marks + 100;
Increase marks of all the students by 100.
e. g. UPDATE student SET City =  ̳Udhampur‘ WHERE city =  ̳Jammu‘;
changes the city of those students to Udhampur whose city is Jammu.
We can also update multiple columns with update command, like
e. g. UPDATE student set marks = marks + 20, city =  ̳Jalandhar‘
WHERE city NOT IN ( ̳Jammu‘,‘Udhampur‘);
CREATE VIEW Command
In SQL we can create a view of the already existing table that contains specific attributes of the table.
e. g. the table student that we created contains following fields:
Student (Roll_no, Name, Marks, Class, City)
Suppose we need to create a view v_student that contains Roll_no,name and class of student table,
then Create View command can be used:
CREATE VIEW v_student AS SELECT Roll_no, Name, Class FROM student;
The above command create a virtual table (view) named v_student that has three attributes as mentioned and all the rows under those attributes as in student table.We can also create a view from an existing table based on some specific conditions, like CREATE VIEW v_student AS SELECT Roll_no, Name, Class FROM student WHERE City <>‘Jammu‘;
The main difference between a Table and view is that A Table is a repository of data. The table resides physically in the database. A View is not a part of the database's physical representation. It is created on a table or another view.
It is precompiled, so that data retrieval behaves faster, and also provides a secure accessibility mechanism.
ALTER TABLE Command
In SQL if we ever need to change the structure of the database then ALTER TABLE command is used. By using this command we can add a column in the existing table, delete a column from a table or modify columns in a table.
Adding a column The syntax to add a column is:-
ALTER TABLE table_name ADD column_name datatype;
e.g
ALTER TABLE student ADD(Address varchar(30));
The above command add a column Address to the table atudent.
If we give command  SELECT * FROM student;
The following data gets displayed on screen:
Roll_no Name Class Marks City
101 Rohan XI 400 Jammu
102 Aneeta Chopra XII 390 Udhampur
103 Pawan Kumar IX 298 Amritsar
104 Rohan IX 376 Jammu
105 Sanjay VII 240 Gurdaspur
113 Anju MAhajan VIII 432
Address
Pathankot
Note that we have just added a column and there will be no data under this attribute. UPDATE command can be used to supply values / data to this column.
Removing a column ALTER TABLE table_name
DROP COLUMN column_name;
e.g ALTER TABLE Student DROP COLUMN Address;
The column Address will be removed from the table student. DROP TABLE Command  Sometimes you may need to drop a table which is not in use. DROP TABLE command is used to Delete / drop a table permanently. It should be kept in mind that we can not drop a table if it contains records. That is first all the rows of the table have to be deleted and only then the table can be dropped. The general syntax of this command is:- DROP TABLE <table_name>;
e.g
DROP TABLE student;
This command will remove the table student

Sunday 16 February 2014

BASIC CONCEPTS OF OOPS & CLASSES AND OBJECTS

Object-Oriented Programming groups related data and functions together in a class, generally making data private and only some functions public. Restricting access decreases coupling and increases cohesion. It has proven to be very effective in reducing the complexity increase with large programs.For small programs may be difficult to see the advantage of OOP over, eg, structured programming because there is little complexity regardless of how it's written.
It helps in programming approach in order to built robust user friendly and efficient software and provides the efficient way to maintain real world software. OOP is an Object Oriented Programming language which is the extension of Procedure Oriented Programming language. OOPs reduce the
code of the program because of the extensive feature of Polymorphism. OOPs have many properties such as DataHiding, Inheritance Data Abstraction, Data Encapsulation and many more. The main aim is to creating an Object to the Entire program and that to we can control entire program using the Object. The main features of OOPS is Polymorphism, Multiple Inheritance, Abstraction and
Encapsulation.

Object: is the basic unit of object-oriented programming. Objects are identified by its unique name. An object represents a particular instance of a class.
An Object is a collection of data members and associated member functions also known as methods.

Classes:
Classes are data types based on which objects are created.
Thus a Class represents a set of individual objects. Characteristics of an object are represented in a class as Properties. The actions that can be performed by objects become functions of the class and are referred to as Methods.
Classes are the blueprints upon which objects are created. E.g when we design a map of the house, the architect first designs it. Once it is designed, the raw material is used to build the house. In this example, Design of the house is CLASS (blueprint) and the house built on the basis of design is an object.
No memory is allocated when a class is created. Memory is allocated only when an object is created, i.e., when an instance of a class is created.

Inheritance:
Inheritance is the process of forming a new class from an existing class or base class. The base class is also known as parent class or super class. The new class that is formed is called derived class.
 Derived class is also known as a child class or sub class. Inheritance helps in reducing the overall code size of the program, which is an important concept in object-oriented programming. It is the process by which one class inherits the properties of another Class.
Different types of Inheritance are:
1) Single Inheritance
2) Multi level Inheritance
3) Multiple Inheritance
4) Hierarchical Inheritance
5) Hybrid Inheritance

Data Abstraction:
Data Abstraction increases the power of programming language by creating user defined data types.
Data Abstraction also represents the needed information in the program without presenting the details.

The concept of abstraction relates to the idea of hiding data that are not needed for presentation. The
main idea behind data abstraction is to give a clear separation between properties of data type and
the associated implementation details.
An Abstract Data Type is defined as a data type that is defined in terms of the operations that it supports and not in terms of its structure or implementation.

 Data Encapsulation:
 Data Encapsulation combines data and functions into a single unit called class.
 Data Encapsulation enables the important concept of data hiding possible.
 Encapsulation is the process of combining data and functions into a single unit   called class. Using the method of encapsulation, the programmer cannot directly access the data. Data is only accessible through the functions present inside the class.

Data hiding is the implementation details of a class that are hidden from the user. Encapsulation alone is a powerful feature that leads to information hiding, abstract data type and friend functions.


Polymorphism:
Poly means many and morphs mean form, so polymorphism means one name multiple form. There are two types of polymorphism: compile time and run time polymorphism.Polymorphism allows routines to use variables of different types at different times. An operator or function can be given different meanings or functions. Polymorphism refers to a single function or multi-functioning operator performing in different ways .

Overloading:
Overloading is one type of Polymorphism. It allows an object to have different meanings, depending on its context. When an exiting operator or function begins to operate on new data type, or class, it is understood to be overloaded.


Re-usability:
This term refers to the ability for multiple programmers to use the same written and debugged existing class of data.
The programmer can incorporate new features to the existing class, further developing the application and allowing users to achieve increased performance.




Friday 14 February 2014

Overview of C++

KEY POINTS:
Introduction to C++
-----------------------------------------------------------------------------------------------------------------------------
C++ is the successor of C language & developed by Bjarne Stroustrup at Bell Laboratories,
New Jersey in 1979.
Tokens- smallest individual unit. Following are the tokens
 -> Keyword-Reserve word that can‘t be used as identifier
 -> Identifiers-Names given to any variable, function, class, union etc.
 -> Literals-Value of specific data type
 -> Variable- memory block of certain size where value can be stored and changed.
 -> Constant- memory block where value can be stored once but can‘t changed later on

 Operator – performs some action on data
--------------------------------------------------------------------------------------------------------------------------------
 1.  Arithmetic(+,-,*,/,%)
 2.  Relational/comparison (<,>,<=,>=,==,!=).
 3.  Logical(AND(&&),OR(||),NOT(!).
 4.  Conditional (? :)
 5.  Increment/Decrement Operators( ++/--)

Precedence of operators:
-------------------------------------------------------------------------------------------------------------------------------
1.     ++(post increment),--(post decrement)
2.     ++(pre increment),--(pre decrement),sizeof !(not),-(unary),+unary plus)
3.     *(multiply), / (divide), %(modulus)
4.     +(add),-(subtract)
5.     <(less than),<=(less than or equal),>(greater than), >=(greater than or equal to)
6.     ==(equal),!=(not equal)
7.     && (logical AND)
8.     ||(logical OR)
9.     ?:(conditional expression)
10.   =(simple assignment) and other assignment operators(arithmetic assignment
operator)
11.   , Comma operator
---------------------------------------------------------------------------------------------------------------------------------
Data type- A specifier to create memory block of some specific size and type. For example –int,float,double,char etc.

cout – It is an object of ostream_withassign class defined in iostream.h header file and used to
display value on monitor.
cin – It is an object of istream_withassign class defined in iostream.h header file and used to read
value from keyboard for specific variable.
comment- Used for better understanding of program statements and escaped by the compiler to
compile . e.g. – single line (//) and multi line(/*....*/)
---------------------------------------------------------------------------------------------------------------------------------
Control structures :
Conditional Control Structures:
-------------------------------------------------------------
1.       if(expression)
          {
          Statements;
          }

2.       if(expression)
          {
          Statements;

          }
          else
          {
          Statements;

          }

3.    switch(integral expression)
{
case :(const expr1)
statement1;
break;
case :(const expr2)
statements2;
break;
default:
statements;


Looping control structures:
-----------------------------------------------------
4. while(expression)
   {
    statements;
   }


5. do
    {
     statements;
    }while(expression);


6. for(initialisation; condition; increment/decrement)
{
statements;
}

Note: any non-zero value of an expression is treated as true and exactly 0 (i.e. all bits contain
0) is treated as false.
Nested loop -loop within loop.
exit()- defined in process.h and used to leave from the program.
break- exit from the current loop.
continue- to skip the remaining statements of the current loop and passes control to the next loop
control statement.
goto- control is unconditionally transferred to the location of local label specified by <identifier>.
For example
A1:
cout<<"test";
goto A1;
Some Standard C++ libraries
iostream.h
Defines stream classes for input/output streams
stdio.h
Standard input and output
ctype.h
Character tests
string.h
String operations
math.h
Mathematical functions such as sin() and cos()
stdlib.h
Utility functions such as malloc() and rand()

Some functions
 isalpha(c)-check whether the argument is alphabetic or not.
 islower(c)- check whether the argument is lowecase or not.
 isupper(c) - check whether the argument is upercase or not.
 isdigit(c)- check whether the argument is digit or not.
 isalnum(c)- check whether the argument is alphanumeric or not.
 tolower()-converts argument in lowercase if its argument is a letter.
 toupper(c)- converts argument in uppercase if its argument is a letter.
 strcat()- concatenates two string.
 strcmp-compare two string.
 pow(x,y)-return x raised to power y.
 sqrt(x)-return square root of x.
 random(num)-return a random number between 0 and (num-1)
 randomize- initializes the random number generator with a random value.
Array- Collection of element of same type that are referred by a common name.
One Dimension array
An array is a continuous memory location holding similar type of data in single row or single
column
Two dimensional array
 A two dimensional array is a continuous memory location holding similar type of data in of
both row sand columns (like a matrix structure).
Function -Self-contained block of code that does some specific task and may return a value.
Function prototypes-Function declaration that specifies the function name, return type and
parameter list of the function.
syntax: return_type function_name(type var1,type var2,....,type varn );
Passing value to function-
 Passing by value
 Passing by address/reference
Function overloading
 Processing of two or more functions having same name but different list of parameters
Function recursion
 Function that call itself either directly or indirectly.
Local variables
 Declared inside the function.
Global variables
 Declared outside all braces { } in a program
Actual Parameters
Variables associated with function name during function call statement.
Formal Parameters
Variables which contains copy of actual parameters inside the function definition.
Structure-Collection of logically related different data types (Primitive and Derived) referenced under
one name.

Nested structure
 A Structure definition within another structure.
 A structure containing object of another structure.
typedef
 Used to define new data type name
#define Directives
 Use to define a constant number or macro or to replace an instruction.
Inline Function
 Inline functions are functions where the call is made to inline functions, the actual code then
gets placed in the calling program.
 What happens when an inline function is written?
 The inline function takes the format as a normal function but when it is compiled it is compiled
as inline code. The function is placed separately as inline function, thus adding readability to
the source program. When the program is compiled, the code present in function body is
replaced in the place of function call.
General Format of inline Function:
The general format of inline function is as follows:
inline datatype function_name(arguments)
inline int MyClass( )
Example:
#include <iostream.h>
int MyClass(int);
void main( )
{int x;
cout <<"\n Enter the Input Value:";
cin>>x;
cout<<"\n The Output is: " << MyClass(x);
}
inline int MyClass(int x1)
{return 5*x1;}
The output of the above program is:
Enter the Input Value: 10
The Output is: 50
The output would be the same even when the inline function is written solely as a function.
The concept, however, is different. When the program is compiled, the code present in the
inline function MyClass ( ) is replaced in the place of function call in the calling program. The
concept of inline function is used in this example because the function is a small line of code.
The above example, when compiled, would have the structure as follows:
#include <iostream.h>
int MyClass(int);
void main( )
{int x;
cout << "\n Enter the Input Value: "; cin>>x;
//The MyClass(x) gets replaced with code return 5*x1;
cout<<"\n The Output is: " << MyClass(x);
}
#include <iostream.h>
int MyClass(int);
void main( )
{int x;
cout <<"\n Enter the Input Value:";
cin>>x;
//Call is made to the function MyClass
cout<<"\n The Output is:" << MyClass(x);
}
int MyClass(int x1)
{return 5*x1;}

Tuesday 4 February 2014

Heads of Important Indian Government Offices


President - Pranab Mukherjee
Vice-President - Mhd Hamid Ansari (Chairman of Rajya Sabha)
Prime Minister - Dr. Manmohan Singh
Defence Minister - A. K. Antony
Finance Minister - P. Chidambaram
Home Affairs Minister - Sushilkumar Shinde

Speaker of LokSabha – Ms.Meera Kumar
Dy. Speaker of LokSabha – KariaMunda
Chairman of RajyaSabha – Dr. Hamid Ansari (Vice President of India)
Dy. Chairman of RajyaSabha – P.J.Kurien
Chief justice of India (CJI) – P. Satha Sivam
Attorney general–G.E. Vahanavathi
Solicitor general – Mohan Parasaran
Comptroller and Auditor General (CAG)– Shashi Kanth Sharma
Chief Election Commissioner – V.S. Sampath
Other election commissioners
 Harishankar Brahma
 Syed Nasim Ahmed Zaidi
Dy.Chairman Planning Commission – MonteksinghAhluwalia
Governor RBI – Raghuram Rajan
Cabinet Secretary – A.K. Seth
Finance Secretary – Rajiv Thakur
Foreign Secretary – Sujatha Singh
National Security Advisor–Shiv SankarMenon
Economic Advisor to PM – K. RangaRajan
Chairman National Knowledge Commission – Sam Pitroda
Chairman of UPSC –D.P.Agarwal
Chairman Finance Commission (14th ) – Y. V. Reddy
National Human Rights Commission (NHRC) – K G Bala Krishnan
National Commission for Women (NCW) – Mamatha Sharma
National Commission for Minorities – WajahatHabibullah
National Commission for SCs – Dr.Buta Singh
National Commission for STs – Ms.Urmila Singh
National Commission for BCs –M N Rao
National Commission for Protection of Child Rights (NCPCR) – V ShanthaSinha
Chairman of University Grants Commission (UGC) – Prof. Veda Prakash

IBPS SPECIALIST OFFICER III :: IBPS IT-OFFICER 2014 MODEL QUESTIONS AND ANSWERS

PROFESSIONAL KNOWLEDGE (IT)
===================================================
1. Computer read which type code I
(1 Ans.) binary code (2) English letter (3) character
(4) integer
(5) None of these

2. Hamming distance is’
(1 Ans.) a theoretical way of measuring errors
(2) a technique for assigning codes to a set of items known to occur with a given probability
(3) a technique for optimizing the intermediate code
(4) All of the above
(5) None of these

3. To find the shortest-path in a weighted graph or network, which of the following algp-rithm is
not used?
(1 Ans.) Warshall’s algorithm
(2) Dijkastra algorithm
(3) Kruskal algorithm
(4) All of the above
(5) None of these

4. The page replacement policy that some times leads to more page faults when the size of the
memory is increased, is
(1 Ans.) FIFO
(2) LRU
(3) MRU
(4) Optimal
(5) None of these

5. The PPP replaced.............
(1) HDLC
(2) OSPF
(3 Ans.) SLIP
(4) PAP
(5) None of these

6. The gate whose output is low if and only if all inputs are high, is
(1 Ans.) NAND
(2) AND
(3) OR
(4) All of these
(5) None of these

7. The ABC bank has implemented WLAN in its network when two or more devices in the network
send data at the same time to another device, the network faces the media access problem.
Which algorithm should the network administrator use to resolve the problem?
(1 Ans.) CSMA/CA
(2) CSMA/CD
(3) SSID Cloaking
(4) MAC Address Filtering
(5) None of these

8. Virtual functions allows you to
(1) create an array of type pointer to base class that can hold pointers to derived classes
(2 Ans.) use the same function call to execute member functions of objects from different classes.
(3) create function that have no body.
(4) group objects of different classes so they can all be accessed by the same function code.
(5) None of these

9. Communication circuits that transmit data in both directions but not at the same time are
operating in :
(1) a simplex mode
(2 Ans.) a half duplex mode
(3) a full duplex mode
(4) an asynchronous mode
(5) None of these

10. Critical section is a program segment
(1) which should run in a certain specified amount of time
(2) which avoids deadlock
(3 Ans.) where shared resources are accessed
(4) which must be endorsed by pair of semaphore operation P and V
(5) None of these

11. A Recurrence Relation
(1) Fibonacci sequence of numbers are type of Recurrence relation
(2) It is called difference equation when two terms will be used interchangeably.
(3) Numeric function is ref-ered to as the solution of the recurrence relation
(4 Ans.) All of the above
(5) None of these

12. Non planar graph with minimum number of vertices have
(1) 9 edges, 6 vertices
(2) 6 edges, 4 vertices
(3) 10 edges, 5 vertices
(4 Ans.) 9 edges, 5 vertices
(5) None of these

13. A language is regular if and only if it is accepted by a finite automation’.
(1 Ans.) The given statement is true
(2) The given statement is false
(3) The given statement is partially true
(4) Sometimes true, sometimes false(5) None of these

14. Which of the following have Fastest speed
(1 Ans.) FDDI ring
(2) None of these
(3) LAN
(4) token bus
(5) ring

15. .................modifies source code and/or data in an effort to make it amenable to future changes.
(1) Reverse engineering
(2 Ans.) Software restructuring
(3) Forward engineering
(4) Software maintenance
(5) None of these

16. Once object oriented programming has been accomplished, unit testing is applied for each
class. Class tests include-
(1) Fault-based testing
(2) Random testing
(3) Partition testing
(4 Ans.) All of the above (5) None of these

17. There are occasions when it does not matter if the function produces 0 or 1 for a given minterm.
Minterms that may produce either 0 or 1 for the function are said to be
(1) Careless conditions
(2 Ans.) Don’t care condition
(3) Maxterm condition
(4) None of these
(5) Minterm condition

18. All the vertices of a walk except very first and very last vertex, is called-
(1 Ans.) Internal vertices
(2) External vertices
(3) Intermediate vertices
(4) Adjacent vertices
(5) None of these

19. The library* files’ that come with C are
(1) Text editor for program development
(2) the compiler and linear
(3) program examples
(4 Ans.) files that contain functions which carry out various commonly used operations and calcula
tions
(5) None of these

20. Which of the follwing are valid characters constant?
(1) ‘in’
(2) ‘11’
(3) ‘10’
(4 Ans.) all of the above (5) None of these

21. In problem analysis, what is to be done?
(1) Structure information
(2 Ans.) Data flow diagram and data dictionary
(3) Structured analysis & prototyping
(4) All of the above
(5) None of these

22. Which of the following is a phase of RAD model?
(1) Business modeling
(2) Data modeling
(3) Application generation
(4 Ans.) All of the above (5) None of these

23. A comment
(1) is a note that can be put into the source code
(2) is ignored by the compiler
(3) starts with the/* character pair (4 Ans.) All of the above (5) None of the above

24. Which of the following is not relevant to networking
(1) low end stand along hubs
(2) stackable hubs
(3) meshnetwork
(4 Ans.) bus hubs
(5) None of these

25. In C++, a function contained within a class is called a-
(1) In built function
(2) User defined function
(3 Ans.) Member function
(4) All of these
(5) None of these

26. A template can be used to create a family of-
(1) Classes
(2) Functions
(3 Ans.) Class and function
(4) All of these
(5) None of these

27. Context free grammar is
(1) A compiler
(2 Ans.) A language generator
(3) A regular expression
(4) All of these
(5) None of these

28. Chaining and Indexing are the starategies of
(1) Contiguous allocation
(2 Ans.) Non-contiguous allocation
(3) Partition allocation
(4) None of these
(5) Static allocation

29. The POST is a series of......... tests.
(1 Ans.) 14
(2) 13
(3) 12
(4) 11
(5) None of these

30. A path in graph G, which contains every vertex of G once and only once?
(1) Eular tour
(2 Ans.) Hamiltonian path
(3) None of these
(4) Eular trail
(5) Hamailtonian tour

31. A tree structured file directory system:
(1 Ans.) allows easy storage and retrieval of file names
(2) is a much debated unnecessary feature
(3) is not essential when we have millions of files
(4) All of the above
(5) None of these

32. The scope resolution operater usually
(1 Ans.) Specifies a particular class
(2) one base class and more than one derived class
(3) resolve ambiguities
(4) All of the above (5) None of these

33. ‘Person’ is
(1) Object
(2 Ans.) Class
(3) Attribute
(4) Structure
(5) None of these

34. Zero has two representations in
(1) 1’s complement
(2 Ans.) sign magnitude
(3) 2'scomplement
(4) All of the above (5) None of these

35. Which are. not property of Binary relations
(1) reflexive relation, symmetric relation, anti symmetrical relation
(2) reflexive, transitive, equivalence relations
(3) transitive, partial ordering relation, symmetric
(4 Ans.) reflexive, partial, chain relation
(5) None of these

36. Which of the following are loaded into main memory when the computer is booted?
(1 Ans.) Internal Command instructions (2) External Command Instructions
(3) Utility programs
(4) Word Processing Instruction
(5) None of these

37. A relation is said to be in INF if:
(1) there is no duplication of data
(2 Ans.) there are no composite attributes in the relation
(3) there are only a few composite attributes
(4) all attributes are of uniform type
(5) None of these

38. Which is false
(1) QBE is based on domain relational calculus.
(2) QUEL is based on tuple relational calculus.
(3) Datalog is based on logical programming language
(4 Ans.) All of the above
(5) None of these

39. The number of flip-flops required in a modulo N counter is
(1) log2(N)+l
(2) Ilog2(N)]
(3 Ans.) [log2(N)l
(4)log2(N-l)
(5) None of these

40. A linker is given object modules for a set of programs that were compiled separately. What
information need not be included in the object module?
(1) Object module
(2) Relocation bits
(3) names and locations of all external symbols defined in the object module
(4 Ans.) Absoulte address of internal symbols
(5) None of these

41. Clipping
(1) It identifies those portion of a picture that are either inside or outside of specified region of
space is referred to as clipping algorithm
(2) There are five types of clipping
(3) Point clipping, Line clipping, Area clipping, Curve clipping Text clipping are examples of
clipping
(4 Ans.) All of the above
(5) None of these

42. In operand
(1) data to be operated
(2) Operand include 8 bit 16 bit data an internal resigters, a memory location
(3) It include also 8 bit or 16 bit address
(4 Ans.) All of the above (5) None of these

43. The PPP frame consists of .............. fields.
(1 Ans.) 7
(2) 5
(3) 6
(4) 8
(5) None of these

44. The ‘end’ manipulator?
(1) appends null character to the stream and flushes it.
(2) causes the next output to be on new line
(3 Ans.) just flushes the stream
(4) All of the above (5) None of these

45. The minimum number of inter chnges needed to convert the array
89, 19, 40, 17, 12, 10, 2, 5, 7, 11,6, 9,70 into heap with maximum element at the root is
(1) 0
(2) 1
(3 Ans.) 2
(4) 3
(5) None of these

46. Which of the following does not form part of an ATM ?
(1) Processor, Card Reader and Printer
(2) Customer Interface. Panel
(3 Ans.) Key Board
(4) Dispenser and Depositor
(5) All of the above.

47. An important application of cryptography, used in computerized commercial and financial
transaction-
(1) Data mining (2) Data warehousing
(3 Ans.) Digital signature
(5) None of these
(4) Media convergence

48. White Box testing, a software testing technique is sometimes called-
(1) Basis path
(2) Graph testing (3) Data flow
(4 Ans.) Glass box testing
(5) None of these

49. Which normal form is considered adequate for normal relational database design?
(1) 5NF
(2) 4NF
(3 Ans.) 3NF
(4) None of these
(5) 2NF

50. In a circular linked list, insertion of a record involves modification of
(1) One pointer
(2 Ans.) two pointer
(3) Multiple pointer
(4) no pointer
(5) None of these


Oracle Reserved Words

Oracle  Reserved Words The following words are reserved by Oracle. That is, they have a special meaning to Oracle and so cannot be redefi...