Sunday, April 13, 2014

Solve question on C++

1) Object is ___
(A) A concept
(B) Abstraction
(C) Thing
(D) All of these

Answer :- (D) All of these

2) Each object is said to be ____ of its class.
(A) Attribute
(B) Instance
(C) Classification
(D) Operations

Answer :- Instance

3) Person is ____
(A) Object
(B) Class
(C) Attribute
(D) Structure

Answer :-  (B) Class

4) A class that serves only a base class from which classes are derived?
(A) Base class
(B) Class
(C) Abstract class
(D) Intermediate class

Answer :- (C) Abstract class

5) In C++ a function contained within a class is called a___
(A) In built function
(B) User defined function
(C) Member function
(D) None of these

Answer :- (C) Member function

6) In C++ , setw is ____
(A) Initialization operator
(B) Conditional operator
(C) Memory allocation operator
(D) Field width operator

Answer :- (C) Member function

7) Which of the following C++  statement is correct?
(A) int *p = new int
(B) int new = *p
(C) int *new = *p
(D) int *p = int new

Answer :- (A)  int *p = new int

8) In C++ by default ,the members of a class are ___
(A) Public
(B)  Private
(C) Both public and private
(D) None of these

Answer :- (B) Private

9) Which of the following operators can be overloaded in C++?
(A) Scope resolution operator
(B) Size of operator
(C) Conditional operator
(D) Arithmetic operator

Answer :- (D) Arithmetic operator

10) Which of the following is different from the group ?
(A) Private
(B) Protected
(C) Public
(D) Friend

Answer :- (D) Friend

11) Which of the following is a type of inheritance ?
(A) Multiple
(B) Multi level
(C) Hierarchical
(D) All of these

Answer : - (D) All of these

12) C++ was developed by ___
(A) Dennis Ritchie
(B) Bjarne Stroustrup
(C) Tannenbaum
(D) Milan Melkovinec

Answer :-  (B) Bjarne Stroustrup

13) A ____  variable provides an alias for a previously defined variable
(A) Global
(B) Local
(C) Refrence
(D) Dynamic

Answer :- (C) Refrence

14) Which statement is true in context of virtual functions?
(A) The virtual functions must be members of some class
(B) Virtual functions cannot be static members
(C) A virtual function can be friend of another class
(D) All of the above

Answer :- (D) All of the above

15) In C++ we can use same function name to create functions that perform a variety of different tasks.This is known as ____.
(A) Global function
(B) Function overloadiing
(C) Inheritance
(D) All of the above

Answer :- (B) Function overloading

16) A template can be used to create a family of ___
(A) Classes
(B) Funtions
(C) Class and function
(D) None of these

Answer :- (C) Class and function

17) Encapsulation is known as ___
(A) Information hiding
(B) Data abstraction
(C) Data about data
(D) None of these

Answer :- (A) Information hiding


18) The objects are __ if all their attribute values are identical.
(A) Identical
(B) Distinct
(C) Same
(D) None

Answer :- (B) Distinct

19) A type of inheritance that permits a class to have more than one super class and to inherit features from all ancestors ___
(A) Inheritance
(B) Multiple inheritance
(C) Subclasses
(D) Super classes

Answer :- (B) Multiple inheritance

20) Actions are performed in an object oriented systems by sending ______ to an object.
(A) Statements
(B) Messages
(C) Control
(D) None of these

Answer  :- (B) Messages

Click here to read more....

Solve Computer Arithmetic -

1) The basic logic operation is _____.
(A) AND
(B) NOR
(C) NAND
(D) NOR

Answer :- (A) AND


2) Which of the following belongs to the logic families of integrated circuits?
(A) Transistor Transistor Logic (TTL)
(B) Metal Oxide Semiconductor (MOS)
(C) Complementary Metal Oxide Semiconductor (CMOS)
(D) All of the above

Answer :- (D) All of the above


3) _________ is preferable in system requiring low power consumption.
(A) Emitter Coupled Logic (ECL)
(B) Metal Oxide Semiconductor (MOS)
(C) Complementary Metal Oxide Semiconductor (CMOS)
(D) Transistor Transistor Logic (TTL)

Answer :- (C)  Complementary Metal Oxide Semiconductor (CMOS)


4) T flip-flop means _______
(A) Timed flip-flop
(B) Toggle flip-flop
(C) Tackle flip-flop
(D) Test flip-flop

Answer  :- (B) Toggle flip-flop


5) Half adder is an example of _____
(A) Combinational circuit
(B) Sequential circuit
(C) Asynchronous circuit
(D) None of these

Answer :- (A) Combinational circuit


6) Full adder is used to _____
(A) 2 bit addition
(B) 3 bit addition
(C) 4 bit addition
(D) Addition of unlimited number of bits

Answer :- (B) 3 bit addition

7) Which of the following flip-flop is different ,in context of their outputs?
(A) SR flip-flop
(B) D flip-flop
(C) JK flip-flop
(D) None of these

Answer :- (C) JK flip-flop


8) Which of the following is not a number system ?
(A) Hexadecimal
(B) Octal
(C) Radix
(D) Binary

Answer :- (C) Radix


9) Which of the following is not a combinational circuit ?
(A) Encoders
(B) Decoders
(C) Registers
(D) Multiplexers

Answer :- (C) Registers


10) Which of the following belongs to DeMorgan's theorems?
(A) x + x =1
(B) xy = yx
(C) (xy)' = x'  +  y'
(D) x . 0 = 0

Answer :- (C) (xy)' = x'  +  y'


11) An encoder has 2n input lines and ____ output lines
(A) 2
(B) n
(C) 2 * n
(D) n * n

Answer :- (B) n


12) 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 ____
(A) Careless conditions
(B) Don't care condition
(C) Minterm condition
(D) Maxterm condition

Answer :- (B) Don't care condition


13) ASCII code for alphabetic character requires ____ bits
(A) 16
(B) 15
(C) 8
(D) 7

Answer :- (D) 7


14) The number that cannot be normalized, in floating point ___
(A) 1
(B) 0
(C) Both (A) and (B)
(D) None of these


Answer :- (B) 0


15) The 3-bit operation code for ADD operation is 001 and indirect memory address is 23 then 16-bit instruction code can be written as ____
(A) 00001000000010111
(B) 1001000000010111
(C) 10001000000010111
(D) None of the above

Answer :- (A) 00001000000010111


16) Which of following is/are application(s) of flip-flop?
(A) Bounce elimination switch
(B) Latch
(C) Counters
(D) All of the above

Answer :- (D) All of the above

Click here to read more ........

Wednesday, April 9, 2014

Solve

Solve


Directions: In each Q1 to Q3 of the following questions, there are five letter groups or words in each question. Four of these letter groups or words are alike in some way, while one is different. Find the one which is different.
Q.1.    (1) black    (2) red    (3) green    (4) paint    (5) yellow
Answer:- (4) paint

Q.2.    (1) BC    (2) MN    (3) PQ    (4) XZ    (5) ST
Answer :-(4)XZ

Q.3.    (1) Mango    (2)Apple    (3) Orange    (4) Guava    (5) Rose
Answer :- (5) Rose


Directions : In each of the following questions, there is a question mark in which only one of the five alternatives given under the question satisfies the same relationship as is found between the two terms to the left of the sign :: given in the question. Find the correct answer

Q.4.Foot : man : : hoof : ?
(1) leg    (2) dog    (3) horse    (4) boy    (5) shoe
Answer :- (3) horse

Q.5.Day : Night : : Kind : ?
(1) Dark    (2) Bright    (3) Cruel    (4) Generous    (5) Gratitude
Answer :-(3) Cruel

Q.6.Hut : mansion : : Rabbit : ?
(1) Hole    (2) Carrot    (3) Elephant    (4) Small    (5) Rat
Answer :- (3) Elephant


Now try the following questions.
Q.7.If the letters in the word TOPS can be rearranged to form a meaningful word beginning with O, the last
letter of that word is your answer. If more than one such word can be formed, M is the answer and if no
such word can be formed, X is the answer.
(1) T    (2) P    (3) M    (4) S    (5) X
Answer :- (4) S

Q.8.‘Some leaders are dishonest. Satyapriya is a leader.’
Which of the following inferences definitely
follows from these statements ?
(1) Satyapriya is honest
(2) Satyapriya is dishonest
(3) Some leaders are honest
(4) Leaders are generally dishonest
(5) Satyapriya is sometimes
Answer :- (3) Some leaders are honest


Directions :
In each of the following questions, you have to find out what will come in place of the question
mark (?).
Q.9. 42 + 73 + 137 = ?
(1) 352 (2) 252
(3) 242
(4) 142
(5) None of these
Answer :-(2) 252

Q.10.  20 ×1/2= ?
(1) 4
(2) 5
(3) 12
(4) 20
(5) None of these
Answer :-(5) None of these

Q.11.  0.7 x 0.5 = ?
(1) 35
(2) 0.35
(3) 0.0035
(4) 0.035
(5) None of these
Answer :-(2) 0.35

Q.12.At 10 rupees each, how many rupees will 6 lemons cost ?
(1) 6
(2) 10 (3) 60 (4) 61
(5) 610
Answer :- (3) 60

Q.13.Which of the following can be exact multiple of 4 ?
(1) 27114
(2) 58204
(3) 48402
(4) 32286
(5) None of these
Answer:- (2) 58204


Q.14.If the profit made by selling a pen for Rs.10 is as much as its cost, what is the cost price of the pen ?
(1) Rs.3/-
(2) Rs.5/-
(3) Rs.10/-
(4) Rs.20/-
(5) None of these
Answer:- (2) Rs.5/-


Directions :
In each of the following questions, select from amongst the five alternatives, the word nearest in meaning
to the word given in capitals.
Q.15.LETHAL
(1) light
(2) dangerous
(3) deadly
(4) cruel
(5) thoughtless
Answer:-(3) deadly

Q.16.CENTENARY
(1) a guard
(2) a hundred years
(3) a very old man
(4) hundred runs
(5) hundredth anniversary
Answer:-(5) hundredth anniversary

Q.17.TRIUMPH
(1) conquer
(2) smash
(3) earn
(4) brave
(5) capture
Answer:-(1) conquer


Directions :
In each of the following questions, select from amongst the five alternatives, the word most opposite in
meaning of the word given in capitals.

Q.18.LIVELY
(1) simple
(2) weak
(3) dull
(4) angry
(5) moron
Answer:-(3) dull

Q.19.INADVERTENT
(1) adequate
(2) available
(3) sluggish
(4) negligent
(5) intentional
Answer:-(5) intentional

Q.20.INEPT
(1) accurate
(2) skilful
(3) sensible
(4) artistic
(5) apt
Answer:-(2) skilful

Click here to read more...

Tuesday, April 8, 2014

COCOMO

COCOMO stands for COnstructive COst MOdel

COCOMO ,COnstrustive COst MOdel is static single variable model .
Barry Bohem introduced COCOMO models.
There is a hierarchical of these models.

Model 1:
Basic COCOMO model is static single-valued model that computers software development effort (and cost)
as a function of program size expressed in estimate lines of code.

Model 2 :
Intermediate COCOMO model computers software development effort as a function of program size and a set of "cost drivers"  that include subjective assessments of product ,hardware ,personnel, project attributes.

Model 3:
Advanced COCOMO model incorporates  all characteristics of the intermediate version with an assessment of the cost driver's impact on each step,like analysis ,design ,etc.

COCOMO can be applied to the following software project's categories.
Organic mode
Embedded mode

 Problem :

KLOC =10.9
E = ab(KLOC)exp(bb)
    =2.4 (10.9)exp(1.05)
    =29.5 person-month
D = cb(E)exp(db)
     =2.5 (29.5) exp (.38)
    = 9.04 months
where ,
D is the chronological month
KLOC is the estimated number of delivered lines (expressed in thousands ) of code for project


The intermediate COCOMO model takes the following form ;

E = ai(LOC)exp(bi) X EAF
where ,
 E is the effort applied in person-month
LOC is the estimated number of delivered lines of code for the project.

The coefficient ai and the exponent bi are :
Software project      ai          bi
Organic                   3.2        1.05
Semi-detached        3.0       1.12
Embedded              2.8       1.20

(cocomo to study online)

for loop - syntax and explaination

The for loop :-

Syntax:
                   for (initialization;condition ;increase)
                          {         ---------;
                                    statement;
                           }

and its main function is to repeat statement while condition remains true , like the while loop .
But in addition ,for provides places to specify an initialization instruction and an increase instruction .
The three expression inside for loop have to be separated by semicolon. 
So this loop is specially designed to perform a repetitive action with a counter.

It works the following way :

1. Initialization is executed .Generally it is an initial value setting for a counter variable .This is executed only once.
2. Condition is checked ,if it is true the loop continues, otherwise the loop finishes and statement is skipped.
3. Statement is executed . As usual , it can be either single instruction or a block of instruction enclosed within curly brackets{}.

Different forms of for loop: -
1.  single statement:
for(i=0;i<10;i++)
statement;

2. compound statement:
for(i=0;i<10;i++)
{
         ----------;
         statement;
         ----------;
         ----------;
}

3. loop with no body

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

4.Multiple initialization and multiple updates separated by comma :-
 for(i=0;j=0;i<10;i++;j++)
statement;

5.for (;i<10;i++)

6.for(;i<10;)

7.for(;;)
statement;

Nesting for statement :-
         One for statement can be written within another for statement .This is called nesting of for statement
for(i=0;i<25;i++)
{
    ------------;
    statement;
      for(j=0;j<10;j++)
         {
                statement;
          }
    ---------;
}
 here for every value of i the inner loop will be executed 10 times.

The for loop is very flexible powerful and most commonly used loop.
It is useful when the number of repetition is known in advanced.

Monday, April 7, 2014

ACID properties of transaction

Transaction :-
                      A transaction is collection of operations that performs a single logical function in a database application that may lead to success or failure in operation maintaining integrity.

ACID properties of transaction :-

Atomicity :-
Transaction must be either performed full or not at all.
It will run to completion as as individual unit ,at the end of which either no change have
occurred to database or database has been changed in consistent manner .
At the end of transaction update it will be accessible to all.

Consistency :-
A correct execution of transaction must take DB from one consistent state to another,
programmer is responsible for this.
This property implies that if database was in consistent state before start of transaction ,then
at any time of termination too it must be consistent.

Independence:-
Transaction must not make its update visible to other transactions.
All actions performed by it must be independent.
This property gives transaction a measure of relative independence.

Durability:-
Once changes are committed must never be lost .
And any updating in database may not loss updates made by transaction.

Sunday, April 6, 2014

SOLVE QUESTION ANSWERS ON OPERATING SYSTEM .


1.One can interface with operating system by means of -------
A) Operating system call in a program
B) Operating system commands
C) Operating system process
D) Both by operating system call and operating system commands

Answer :-  D) Both by operating system call and operating system commands


2. Which of the following is not type of processing ?
A) Serial
B) Network
C) Batch
D) Multiprogramming

Answer :- B) Network


3. Kernel is _____
A) A part of operating system
B) An operating system
C) A hardware
D) A register

Answer :-  A) A part of operating system



4. UNIX operating system is based on ______
A) Language structure
B) Kernel approach
C) Virtual machine
D) Time sharing

Answer :-   B) Kernel approach


5. A transition between two memory resident process in a memory resident process in amultiprograming system is called ______
A) Process switch
B) Mode switch
C) Transition switch
D) None of these

Answer :-    A) Process switch


6. Round robin scheduling algorithm falls under category of _____
A) Preemptive scheduling
B) Non- preemptive scheduling
C) Sometime preemptive sometime non-preemptive
D) None of tehse
Answer :-  A) Preemptive scheduling


7. Paging is  a _______
A) Virtual memory
B) Memory management scheme
C) Allocation of memory
D) Deadlock prevention scheme

Answer  :-    B) Memory management scheme


8. The first version of UNIX was written by _____
A) Dennis Ritchie
B) Andrew S
C) Ken Thompson
D) None of these


Answer :- C) Ken Thompson


9. Chaining and Indexing are the strategies of ______
A) Contiguous allocation
B) Non-contiguous allocation
C) Partition allocation
D) Static allocation

Answer :-  B) Non-contiguous allocation



10. Wasting of memory within a partition ,due to a difference in size of a partition and of the object resident within it is called _____
A) External fragmentation
B) Internal fragmentation
C) Compaction
D) Coalescing

Answer :-   B) Internal fragmentation


11.Which of the following is an operating system call ?
A) CREATE
B) LINK
C) SYSTEM
D) All of these

Answer :-    D) All of these


12.The primary job as the operating  system of a computer is to
A) command resources
B) manage resources
C) provide utilities
D) be use friendly

Answer : -  B) manage resources



13.Dirty bit for a page in a page table
A) helps avoid unnecessary writes on a paging device
B) helps maintain LRU information
C) allows only read on a page
D) none of these

Answer : -   A) helps avoid unnecessary writes on a paging device

14. The term "operating system " means
A) a set of programme which controls computer working
B) the way a computer operator works
C) conversion of high language into machine code
D)  the way a floppy disk drive operates

Answer :-  A) a set of programme which controls computer working


15. Windows is a/an
A) operating system
B) user interface
C) operating environment
D) programming platform

Answer :-  C) operating environment


16. When did IBM released teh first version of its Disk Operating System (DOS) version 1.0?
A) 1981
B) 1982
C) 1983
D) 1984


Answer :- A) 1981



Click here to read more .......

From Side Hustle to Main Income: 7 Proven Ways to Make Money Online in 2025

  From Side Hustle to Main Income: 7 Proven Ways to Make Money Online in 2025 Introduction: The New Era of Earning – Why 2025 is Your Year t...