Sunday, April 20, 2014

Study material of Computer Science :-


127.0.0.1 is is a special purpose IP address conventionally used as a computer's loopback address.

Definition Thrashing :-
In computer science, thrashing occurs when a computer's virtual memory subsystem is in a constant state of paging, rapidly exchanging data in memory for data on disk, to the exclusion of most application-level processing

Virtual Memory:-
In computing, virtual memory is a memory management technique that is implemented using both hardware and software. It maps memory addresses used by a program, called virtual addresses, into physical addresses in computer memory. Main storage as seen by a process or task appears as a contiguous address space or collection of contiguous segments.

The time taken to move the disk arm to the desired cylinder is called the :seek time

Class A
0    . 0   . 0   . 0      =  00000000.00000000.00000000.00000000
127.255.255.255   =  01111111.11111111.11111111.11111111
                                  0nnnnnnn.HHHHHHHH.HHHHHHHH.HHHHHHHH
Class B
128. 0. 0. 0          = 10000000.00000000.00000000.00000000
191.255.255.255 = 10111111.11111111.11111111.11111111
                               10nnnnnn.nnnnnnnn.HHHHHHHH.HHHHHHHH
Class C
192. 0. 0. 0          = 11000000.00000000.00000000.00000000
223.255.255.255 = 11011111.11111111.11111111.11111111
                               110nnnnn.nnnnnnnn.nnnnnnnn.HHHHHHHH
Class D
224. 0. 0. 0          = 11100000.00000000.00000000.00000000
239.255.255.255 = 11101111.11111111.11111111.11111111
                               1110XXXX.XXXXXXXX.XXXXXXXX.XXXXXXXX
Class E
240. 0. 0. 0          = 11110000.00000000.00000000.00000000
255.255.255.255 = 11111111.11111111.11111111.11111111
                               1111XXXX.XXXXXXXX.XXXXXXXX.XXXXXXXX
Where:
n indicates a binary slot used for network ID.
H indicates a binary slot used for host ID.
X indicates a binary slot (without specified purpose)

190.255.254.254 -class B

Friday, April 18, 2014

Solve Practice questions of Computer Science

Solve Practice questions of Computer Science




1. Decryption & Encryption of data are the responsibility of the ___ layer.

(A) Physical
(B) Data link
(C) Presentation
(D) Session
(E) Application

Answer :- (C) Presentation



2. LANs can be connected by devices called ____ which operate in the data link layer?

(A) Hub
(B) Bridges
(C) HDLC
(D) Tunnel
(E) None of these

Answer :- (B) Bridges



Click here to read more.....



Thursday, April 17, 2014

Multiplexers

Multiplexer :-
                        It is known as MUX..
                        Multiplexing is the process of connecting many inputs to one output it is "many into one " process with appropriate logic control signals.
                        Multiplexer is a basic block or basic logic combinational circuit with
i) 'n' input lines
ii) 'm' control lines / selector lines
iii) one output line 'Y'

    It requires OR gate in the O/P.
  
   It cannot be used as a decoder.

   Example :- IC 74153,74157
 To calculate Select line  -  Formula :-         2m = n
where, n is the input lines
            m is the control lines

4:1 Multiplexer :
Truth table :-

S1        S0        Y =      
00D0
01D1
10D2
11D3

It has 4 input lines (D0 ,D1,D2,D3) two control lines (S1 S0) called  select lines and one output line by 'Y'
Working:-
1) When the control word is S1 and S0 is 0 0 then Y = D0
2) When the control word is S1 and S0 is 0 1 then Y = D1
3) When the control word is S1 and S0 is 1 0 then Y = D2
4) When the control word is S1 and S0 is 1 1 then Y = D3

Note that at any instant only one AND is enabled allowing only one data line transmission to the common output line.

Wednesday, April 16, 2014

Solve questions

Solve questions





1.In relational database row and column is called as ____and ____respectively.

(A)Tuple; Attribute
(B)Attribute; Tuple
(C)Tupple;Domain
(D)Attribute; Domain
(E)None of these

Answer :- (A)Tuple; Attribute

2.Arrange the following in increasing order of their size.

 (A) Database<File<Record<Field<Byte<Bit
 (B) Bit<Byte<Field<Record<File<Database
 (C) Bit>Byte>Record>Field>File>Database
 (D) Bit>Byte>File>Record>Field>Database


Answer :-   (B) Bit<Byte<Field<Record<File<Database

3. Round robin scheduling is essentially the preemptive version of

(A) FIFO
(B)Shortest job first
(C) Shortest remaining
(D)Longest time first
(E) None of these

Answer :- (A) FIFO

4. Which of the following identifies specific web page and its computer on the web page?

(A) Web site
(B) URL
(C) Web site address
(D) Domain Name
(E) None of these

Answer :- (B) URL

5.Communication handler is basically an ____ 16 bit micro controller?

(A) 8085
(B) 8086
(C) 8086A
(D) 80C186
(E) None of these

Answer :- (D) 80C186

6.GSM stands for ____

(A) General System for Mobile Communication
(B)Global System for Mobile Communication
(C) Guided System for Mobile Communication
(D) Growing System for Mobile Communication
(E) None of these

Answer :- (B) Global System for Mobile Communication

7.EDI refers to ----

(A) Electronic Data Interface
(B) Electric Device Interface
(C) Electronic Data Interchange
(D)Electronic Design Interface

Answer :- (C) Electronic Data Interchange

8.PAN refers to_____

(A) Peer Area Network
(B) Personnel Area Network
(C) Personal Area Network
(D) Payment Application Network

Answer :- (C) Personal Area Network

9.E-Commerce refers to ___

(A)Electrical Commerce
(B) Electronic Commerce
(C)Evolutionary Commerce
(D) Effective Commerce

Answer :- (B) Electronic Commerce

10.Which of the following is a type of E-commerce?

(A) B2B  (Business to Business)
(B) B2C  (Business to Consumer)
(C) C2C  (Consumer to Consumer)
(D) All the above

Answer :- (D) All the above


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



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 ........

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.

Featured posts

Ethiopian culture calendar language

Ethiopian culture, calendar, language  The Ethiopian language, specifically Amharic, uses a script called Ge'ez script. It consists of 3...

Popular posts