Professional Documents
Culture Documents
This type of network is mostly used in one building and in which the connected
computers are not more than 256.
A LAN connects network devices over a relatively short distance. A networked office
building, school, or home usually contains a single LAN, though sometimes one building
will contain a few small LANs, and occasionally a LAN will span a group of nearby
buildings. In IP networking, one can conceive of a LAN as a single IP subnet (though this
is not necessarily true in practice).
Besides operating in a limited space, LANs include several other distinctive features.
LANs are typically owned, controlled, and managed by a single person or organization.
They also use certain specific connectivity technologies, primarily Ethernet and Token
Ring.
The distinction between a LAN and a WAN involves the physical distance that the
network spans. A third category, the MAN, also fit into this scheme as it too is centered
on a distance-based concept.
What the topology is:- the way in which connections are made and arrangement of
computer is referred as topology.
Two kinds of Topologies are: Physical and Logical.
Physical topologies are bus, star , ring and physical mesh topology.
Bus:- in this type of topology the computers are connected by a single cable and we use
terminator at the end of the cable that is used to bounce back the signal. In which we
have the logical topology Ethernet 10 Base 2. Repeaters are used in the place of Hubs.
Star:- the computers are arranged in the form of star and in which we have a central
hub . the logical topology that works here is Ethernet 10 Base 5. trouble shooting is easy
in star just bcoz of Hub.
Ring:- when we need high performance network we use ring topology in which
computers are arranged in form of ring . it is an expensive one . we use token passing
method in this topology . logical topology is FDDI(Fiber Distributed Data Interface).
MAN: A Metropolitan Area Network connects an area larger than a LAN but smaller than
a WAN, such as a city, with dedicated or high-performance hardware.
For example: if we have network b/w Rawalpindi and Islamabad or Karachi and
Hyderabad then it is dubbed as MAN.
Now what is a relationship?It is a binding factor which associates two or more (instances
of)entity types together to form a smart Database which will be helpful for user(easily
modified or updated) as well as for the MIS and DSS (to get information whenever
needed in a detailed fashion).What happens when a relationship is created?Relationship
acts like a glue to the entities to join them together.Or should I illustrate it more
meaningfully as:"Relationship is an association among the instances of one or more than
one entity types".
Here Part-I "introduction to Entity, Relationship and E-R Model" finishes here.In the next
part I will describe how an E-R model is developed and what are different kinds of E-R
models.
Computer languages are divided into two major classes. (1).Procedural Programming
Languages and (2).Object Oriented programming Languages. Today we got to discuss
the second class so let's start with it.
Second query is answered as so; Same functions and procedures used in PPLs are
extended and re-organized in a novel way. Making it closer to the nature but yet has a
drawback of the lack of elucidation which makes it harder to understand. It means that
the OOPL(s) have the same state and behavior and a real high level unit called object to
make the programming dynamic and faster.
Now to define OOP, firstly one should learn what an object stands for?
Object is everything and just a black box. This statement means that everything present
on the suface of the planet is an object, while taking OOP as an ad hoc it is merely a box
which has a function to receive and transmit data according to the signals or commands.
Making it easier to understand I will put it this way. OOP is something which groups Data
and Operations into modular units called Object. This object will receive signals in the
form of command syntax will operate the data the way, it(code) is directing and then
finally to bring the result back to the programmer alongwith the command control.
Here we reach a conclusion and in a better postition to define OOP.
"The insight of object-oriented programming is to combine state and behavior, data and
operations on data, in a high-level unit, an object, and to give it the language support"
That was a brief introduction to the OOP(L). Any kind of supplementation has got full
scope and will surely get a decent response.
wo of the more common data objects found in computer algorithms are stacks and
queues.
Stacks are data structures, which maintain the order of last-in, first-out (LIFO)
Queues are data structures, which maintain the order of first-in, first-out (FIFO)
***Stack: A stack is a storage device that stores information in such a way that the
item stored last is the first item retrieved. A stack is an ordered list in which all
insertions and deletions are made at one end, called the top.
Stack Pointer: the register that holds the address for the stack is called a stack pointer
(SP)coz its value always points at the top item in the stack.
Operations of a Stack
The operations of a stack can be matched to the stack of trays. The last tray placed on
top of the stack is the first to be taken off. The two operations; performed on a stack are
insertion and deletion of items.Insertion and deletion, both acted upon at one end of the
list (called the top).
Push(X)
Insert element with value X at top of stack.
Pop()
Remove top element of stack
These operations are simulated by incrementing or decrementing the stack pointer
register.
The PUSH operation is implemented with the following sequence of micro operations:
SP SP+1 (increment stack pointer)
M [SP]DR (write item on top of the stack)
If (SP=0) then (FULL1) (check if stack is full)
EMPTY0 (Mark the stack not empty)
The POP operation is implemented with the following sequence of micro operations:
DR M [SP] (Read item from the top of stack)
SPSP-1 (Decrement stack pointer)
If (SP=0) then (EMPTY1) (check if stack is empty)
FULL0 (Mark the stack is not full)
***Queue: A queue is an ordered list in which all insertions take place at one end, the
rear, while all deletions take place at the other end, the front. Like a line of people
waiting for some service, a queue acquires new elements at one end (the rear of the
queue) and releases old elements at the other (the front). Queues are more difficult to
implement than stacks, because action happens at both ends.
Queue as an Abstract Data Type
Following is the abstract data type definition for queues, with the conventional names for
the operations:
create
Create a new, empty queue object.
empty
Determine whether the queue is empty; return true if it is and false if it is not.
enqueue
Add a new element at the rear of a queue.
dequeue
Remove an element from the front of the queue and return it. (This operation cannot be
performed if the queue is empty.)
front
Return the element at the front of the queue (without removing it from the queue).
(Again, this operation cannot be performed if the queue is empty.)
Types of Queues : some of them are given below:
Circular Queues :Circular queues let us reuse empty space.
Double-ended queues - These are data structures which support both push and pop and
enqueue/dequeue operations.
Priority Queues(heaps) - Supports insertions and ``remove minimum'' operations which
useful in simulations to maintain a queue of time events.
this is what the brief account in context of stack and queries
There are some terminologies could help us a lot while writing down an essay over
Stacks and Ques in exams like; infix, Polish or Parenthesis-free notation.
Infix is the ordinary notation for writing expressions, where operators separate
arguments.
for example,
3+7
while in the case of Polish notation which is really useful for stack oriented evaluation
operater comes after the arguments. for example,
3, 5, +(Polish notation) => 3+5 (infix notation) and
10 , 6, 9, *, + (Polish notation) => 10+(6*9) (infix notation)etc
A polish expression could better be evaluated by such algorithm using two stacks. A
polish stack will contain polish expression and the evaluation stack stores the
intemediate values during execution.
Lets evaluate the polish expressions now. We will use A, B and C to hold data. What will
happen when the program will execute. The following actions will be done:
1. If the polish stack is empty, halt with the top e. stack as the answer.
2. If stack is not empty, pop the polish stack into A.
3. If A is a value then push A onto the e. stack.
4. If A is an operator then pop the e. stack twice, first into C and then into B. Then do
the computation of B and C and then operate them on by A and push the result into e.
stack. Go to step 1.
That was a curt introduction to the evaluation of Stacks and what are polish notations