Computer Network: What Is Unicast?
Computer Network: What Is Unicast?
Computer Network: What Is Unicast?
1. OSI Layer.
2. Subnetting
3. Protocol
4. Topology
5. Switch\Router\Hub
6. Bandwidth
7. Domain Vs workgroup
8. Unicast\Multicast\Broad cast
9. Simplex\Half-duplex\Full-duplex
10. Various Port(Such as HTTP, SMTP .etc……)
11. Private IP\Public IP
12. TCP\IP\UDP
13. Circuit Switching\Packet Switching
14. Encapsulation
** What is Bandwidth ?
Answer: Bandwidth is also defined as the amount of data that can be transmitted in a fixed
amount of time. For digital devices, the bandwidth is usually expressed in bits per second(bps) or
bytes per second. For analog devices, the bandwidth is expressed in cycles per second, or Hertz (Hz).
Or,
** What is Unicast?
Answer: Unicast is a type of communication where data is sent from one computer to
another computer.
In Unicast type of communication, there is only one sender, and one receiver.
Example:
1) Browsing a website. (Webserver is the sender and your computer is the receiver.)
2) Downloading a file from a FTP Server. (FTP Server is the sender and your computer is the
receiver.)
** What is Multicast?
Devices which are interested in a particular Multicast traffic must join to that Multicast group
to receive the traffic. IP Multicast Groups are identified by Multicast IP Addresses (IPv4
Class D Addresses)
In Multicast, the sender transmit only one copy of data and it is delivered and/or processed to
many devices (Not as delivered and processed by all devices as in Broadcast) who are
interested in that traffic.
** What is Broadcast?
Answer: Broadcast is a type of communication where data is sent from one computer
once and a copy of that data will be forwarded to all the devices.
In Broadcast, there is only one sender and the data is sent only once. But the Broadcast data is
delivered to all connected devices.
Switches by design will forward the broadcast traffic and Routers by design will drop the
broadcast traffic. In other words, Routers will not allow a broadcast from one LAN to cross
the Router and reach another Network Segment. The primary function of a Router is to divide
a big Broadcast domain to Multiple smaller Broadcast domain.
Example: Radio.
Half-duplex: In half duplex mode, data can be transmitted in both directions on a signal carrier
except not at the same time.
Example: walkie-talkie.
Full-duplex: Full-duplex data transmission means that data can be transmitted in both directions
on a signal carrier at the same time. For example, on a local area network with a technology that has
full-duplex transmission, one workstation can be sending data on the line while another workstation
is receiving data.
What is a workgroup?
Answer: Workgroup is Microsoft's term for peer-to-peer local area network. Computers
running Microsoft operating systems in the same workgroup may share files, printers, or
Internet connection. Workgroup contrasts with a domain, in which computers rely on
centralized authentication.
Or, In computer networking, a workgroup is a collection of computers on a local area network (LAN)
that share common resources and responsibilities. The term is most commonly associated with
Microsoft Windows workgroups but also applies to other environments.
Answer: A Windows domain is a form of a computer network in which all user accounts,
computers, printers and other security principals, are registered with a central database
located on one or more clusters of central computers known as domain controllers.
Authentication takes place on domain controllers.
Or, A group of computers and devices on a network that are administered as a unit with common
rules and procedures. Within the Internet, domains are defined by the IP address. All devices sharing
a common part of the IP address are said to be in the same domain.
&************************
Workgroup Domain
Peer-to-peer Windows
Network type Client/server network
computer network
User needs to have separate User can log on at any
Log in log in id and password at each workstation via their account
workstation and access domain resources
Computers are limited to There can be up to 2000
Workstations
maximum 10 computers
Each user controls the One administrator to
Administrator resources and security locally administer the domain and its
on their PC's users and resources.
The computers can be on
All computers must be on the
Location different local networks, i.e.
same local network or subnet.
anywhere in the world.
One can make only limited
changes to a computer's
Each user controls the
settings because network
Computer's settings settings on their own
administrators often want to
computer. No central settings.
ensure consistency among
computers.
Each computer must be
Changes made to one are
changed manually or once
Changes automatically made to all
changed must be transferred
computers
to each computer.
User needs to have separate Domain users must provide a
log in id and password at each password or other credentials
Security
workstation, but once logged each time they access the
in can access the computer. domain.
Answer: Most common protocols used in computer networks and the internet are TCP
(Transmission Control Protocol), UDP (User Datagram Protocol), and IP (Internet
Protocol). A port in computer networking is a logical access channel for communication
between two devices.
What is the range of port numbers?
Answer: Port numbers range from 0 to 65536, but only port numbers 0 to 1024 are reserved
for privileged services and designated as well-known ports. This list of well-known port
numbers specifies the port used by the server process as its contact port.
Answer: Well known SCTP, TCP and UDP ports, 0 through 999. Links: The well known
ports are assigned by IANA in the range of 0 to 1023.
Answer: Port 22 Details. Old verson of pcAnywhere uses port 22/udp (no relation to ssh
and port 22/tcp). The real pcAnywhere port is 5632. The value 0x0016 (hex) is 22 decimal;
the value of 0x1600 (hex) is 5632 decimal.
(RFC 4513)
FTP over TLS/SSL TCP 989/990 Again, just like the previous two entries,
FTP over TLS/SSL uses the FTP
(RFC 4217) protocol which is then secured using
either SSL or TLS.
** Packet switching
Answer: Packet switching is a method for sending data whereby the data is divided in packets.
Each packet is given a header containing information of the destination.
Packet switching is a method for sending data whereby the data is divided in packets. Each
packet is given a header containing information of the destination. Each packet is forwarded
through the network to the destination using this information. At the destination the data has
to be reassembled from the received packages.
After reaching the destination through different routes, the packets are rearranged to
form the original message.
Database
1. Key
a) Primary key
b) Foregin key
c) Super key
d) Candidate key
e) Unique key
f) Composite key
2. ACID properties.
3. ERD
4. Normalization
5. Join
6. DDL\DML
7. SQL
8. Aggregate function
9. Cardinality
Answer: ACID Property is the most important part of the database. ACID stands for
Atomicity Consistency Isolation Durability.
Atomicity: This means that “all or nothing”. When an update occurs to a database either all
or none of the update will become available to anyone beyond the user. This update to the
database is called a transaction and it either commits or aborts.
Consistency: It ensures that any changes to values in an instance are consistent with changes
to other values in the same instance.
Normalization:
Normalization is a technique which is used to organize the data in the database. It is a
systematic approach to remove the data redundancy. Normalization is mainly used for two
purpose,
Without normalization 3 anomalies occurred and it becomes difficult to handle and update
data. To understand these anomalies let’s take an Student table
1. Updation Anamoly – To update address of a student who occurs twice or more than
twice in a table, we will have to updateAddress column in all the rows, else data will
become inconsistent.
2. Insertion Anamoly – Suppose for a new admission, we have a Student id, name and
address of a student but if student has not opted for any subject yet then we have to
insertNULL there, leading to Insertion Anamoly.
3. Deletion Anamoly – If id 401 has only one subject and temporarily he drops it, when
we delete that row, entire student record will be deleted along with i
Normalization Form:
As per First Normal Form, no two rows of data must contain repeating data i.e., whenever we
search for a particular result the multiple columns cannot be used to fetch the same row.
Each table should be organized into rows, and each row should have a primary key that
distinguishes it as unique.
GET EBOOK
Using the First Normal Form, data redundancy increases, as there will be many columns with
same data in multiple rows but each row as a whole will be unique.
As per the Second Normal Form there must not be any partial dependency of any column on
primary key. It means that for a table that has concatenated primary key, each column in the
table that is not part of the primary key must depend upon the entire concatenated key for its
existence.
For example:
Student Age
Akshay 15
Charu 14
Disha 17
In Student Table the candidate key will be Student column, because all other column i.e Age
is dependent on it.
Student Subject
Akshay Maths
Akshay Physics
Charu Biology
Disha Maths
In Subject Table the candidate key will be {Student, Subject} column. Now, both the above
tables qualifies for Second Normal Form and will never suffer from Update Anomalies.
Third Normal Form:
A relation is in third normal form (3NF) if it is in second normal form and it contains
no transitive dependencies.
Consider relation R containing attributes A, B and C. R(A, B, C)
If A → B and B → C then A → C
Transitive Dependency: Three attributes with the above dependencies.
For example:
Student_details table
ID Name Subject
Address Table:
This is a higher version of third normal form. This form deals with certain type of anamoly
that is not handled by 3NF. A 3NF table which does not have multiple overlapping candidate
keys is said to be in BCNF. For a table to be in BCNF, following conditions must be
satisfied:
RDMS Advantages
1. Data is only stored once so multiple documentation changes are not required
2. Better safety measures
3. The table arrangement is straightforward and simple for database users to
appreciate and use.
4. RDBMSs permit numerous database users to admittance a database concurrently.
5. RDBMS agree to the database manager to limit admission to certified users, and
gift rights to entity users depending on the kinds of database work they do
6. RDBMSs offer admission to the database via a server daemon, a dedicated software
program that responds to requirements on a set of connections, and enables database
users to connect and make use of the database.
SQL Features
High Performance.
High Availability.
Scalability and Flexibility
Robust Transactional Support.
High Security.
Comprehensive Application Development.
Management Ease.
Open Source.
Typical SQL
SQL type identifier Description
datatype
Character string of fixed
SQL_CHAR CHAR(n)
string length n.
Variable-length character
SQL_VARCHAR VARCHAR(n) string with a maximum
string length n.
Variable length character
SQL_LONGVARCHAR LONG VARCHAR data. Maximum length is
data source–dependent.[9]
Unicode character string of
SQL_WCHAR WCHAR(n)
fixed string length n
Unicode variable-length
SQL_WVARCHAR VARWCHAR(n) character string with a
maximum string length n
Unicode variable-length
LONGWVARCHA character data. Maximum
SQL_WLONGVARCHAR
R length is data source–
dependent
Signed, exact, numeric
SQL_DECIMAL DECIMAL(p,s) value with a precision of at
least p and scale s.
Signed, exact, numeric
SQL_NUMERIC NUMERIC(p,s) value with aprecision p and
scale s
Exact numeric value with
SQL_SMALLINT SMALLINT
precision 5 and scale 0
Exact numeric value with
SQL_INTEGER INTEGER
precision 10 and scale 0
Signed, approximate,
SQL_REAL REAL numeric value with a
binary precision
Signed, approximate,
numeric value with a
SQL_FLOAT FLOAT(p)
binary precision of at
least p.
Signed, approximate,
DOUBLE
SQL_DOUBLE numeric value with a
PRECISION
binary precision 53
SQL_BIT BIT Single bit binary data.
SQL_TINYINT TINYINT Exact numeric value with
precision 3 and scale 0
Exact numeric value with
precision 19 (if signed) or
SQL_BIGINT BIGINT
20 (if unsigned) and scale
0
Binary data of fixed
SQL_BINARY BINARY(n)
length n.
Variable length binary data
of maximum length n. The
SQL_VARBINARY VARBINARY(n)
maximum is set by the
user.
Variable length binary
LONG
SQL_LONGVARBINARY data. Maximum length is
VARBINARY
data source–dependent.
Year, month, and day
fields, conforming to the
SQL_TYPE_DATE DATE
rules of the Gregorian
calendar.
Hour, minute, and second
fields, with valid values for
hours of 00 to 23, valid
values for minutes of 00 to
SQL_TYPE_TIME TIME(p)
59, and valid values for
seconds of 00 to 61.
Precision p indicates the
seconds precision.
Year, month, day, hour,
minute, and second fields,
SQL_TYPE_TIMESTAMP TIMESTAMP(p) with valid values as
defined for the DATE and
TIME data types.
Year, month, day, hour,
minute, second, utchour,
and utcminute fields. The
SQL_TYPE_UTCDATETIME UTCDATETIME
utchour and utcminute
fields have 1/10
microsecond precision.
Hour, minute, second,
utchour, and utcminute
SQL_TYPE_UTCTIME UTCTIME fields. The utchour and
utcminute fields have 1/10
microsecond precision..
Number of months
INTERVAL
SQL_INTERVAL_MONTH between two dates; p is the
MONTH(p)
interval leading precision.
Number of years between
INTERVAL
SQL_INTERVAL_YEAR two dates; p is the interval
YEAR(p)
leading precision.
SQL_INTERVAL_YEAR_TO_MONTH INTERVAL Number of years and
months between two
YEAR(p) TO
dates; p is the interval
MONTH
leading precision.
Number of days between
INTERVAL
SQL_INTERVAL_DAY two dates; p is the interval
DAY(p)
leading precision.
Number of hours between
INTERVAL
SQL_INTERVAL_HOUR two date/times; p is the
HOUR(p)
interval leading precision.
Number of minutes
INTERVAL between two
SQL_INTERVAL_MINUTE
MINUTE(p) date/times; p is the interval
leading precision.
Number of seconds
between two
INTERVAL date/times; p is the interval
SQL_INTERVAL_SECOND
SECOND(p,q) leading precision and q is
the interval seconds
precision.
Number of days/hours
INTERVAL between two
SQL_INTERVAL_DAY_TO_HOUR
DAY(p) TO HOUR date/times; p is the interval
leading precision.
Number of
INTERVAL days/hours/minutes
SQL_INTERVAL_DAY_TO_MINUTE DAY(p) TO between two
MINUTE date/times; p is the interval
leading precision.
Number of
days/hours/minutes/second
INTERVAL s between two
SQL_INTERVAL_DAY_TO_SECOND DAY(p) TO date/times; p is the interval
SECOND(q) leading precision and q is
the interval seconds
precision.
Number of hours/minutes
INTERVAL
between two
SQL_INTERVAL_HOUR_TO_MINUTE HOUR(p) TO
date/times; p is the interval
MINUTE
leading precision.
Number of
hours/minutes/seconds
INTERVAL between two
SQL_INTERVAL_HOUR_TO_SECOND HOUR(p) TO date/times; p is the interval
SECOND(q) leading precision and q is
the interval seconds
precision.
SQL_INTERVAL_MINUTE_TO_SECON INTERVAL Number of
D MINUTE(p) TO minutes/seconds between
SECOND(q) two date/times; p is the
interval leading precision
and q is the interval
seconds precision.
SQL_GUID GUID Fixed length GUID.
JOINS
Join is used to combine rows of two or more tables by using common values.
Example:
WHERE Student_details.Name=Personal_detail.Name;
1. Inner Join
2. Left Join
3. Right Join
4. Full Join
Inner Join:
Left Join:
It returns all the values of the left table and matched the rows from the right table.
Syntax:
SELECT column_name
FROM table1
ON table1.column_name=table2.column_name;
Example:
FROM Student_details
ON Student_details.Name= Personal_details.Name;
Right Join:
It returns all the values of the right table and matched the rows from the left table.
Syntax:
SELECT column_name
FROM table1
ON table1.column_name=table2.column_name;
Example:
FROM Student_details
ON Student_details.Name= Personal_details.Name;
FULL Join:
Full join returns all the rows from the left table and the right table.
Syntax:
SELECT column_name
FROM table1
ON table1.column_name=table2.column_name;
Example:
FROM Student_details
ON Student_details.Name= Personal_details.Name;
SQL Functions
SQL(Structured Query Language) has got a huge number of functions. This article will give a
description of them. The SQL functions are as follows:
• AVG (Transact-SQL)
Returns the average of the inputs. Ignores the Null ones
• CHECKSUM_AGG (Transact-SQL)
Gives back the checksum. Ignores the Null ones. OVER clause may follow.
• COUNT (Transact-SQL)
Returns the quantity of values in a set. Returns int.
• COUNT_BIG (Transact-SQL)
Returns the number of items in a group. Returns bigint.
• GROUPING (Transact-SQL)
Returns 1 if aggregated or 0 if not .
• MAX (Transact-SQL)
Accesses information from a succeeding row in the identical outcome group devoid of
the self-join .
• PERCENTILE_CONT (Transact-SQL)
Finds out a percentile depending on a nonstop sharing of the column value
• PERCENTILE_DISC (Transact-SQL)
Calculates a certain percentile for sorted values in an entire
• PERCENT_RANK (Transact-SQL)
Computes the relative rank of a row within a group of rows.
• TERTIARY_WEIGHTS (Transact-SQL)
Gives back a binary string for every value in a non-Unicode string statement
Asymmetric
• ASYMKEY_ID
• ENCRYPTBYCert
• DECRYPTBYASYMKEY
• ENCRYPTBYASYMKEY
• ASYMKEYPROPERTY
• DECRYPTBYCERT
All these functions are also non-predestined. This means they do not every time give back the
same outputs
• JSON_QUERY
Takes out an object from the JSON string.
One to one: This cardinality connects one single object with another single object.
One to many: This cardinality connects one single object with many single objects.
Many to many: This cardinality connects many single objects with many other single
objects.
Many to one: This cardinality connects many objects with one single object
Cardinality
The number of times an entity of an entity set participates in a relationship set is known
as cardinality. Cardinality can be of different types:
one to one: When each entity in each entity set can take part only once in the relationship,
the cardinality is one to one. Let us assume that a male can marry to one female and a female
can marry to one male. So the relationship will be one to one.
many to one: When entities in one entity set can take part only once in the relationship
set and entities in other entity set can take part more than once in the relationship set,
cardinality is many to one. Let us assume that a student can take only one course but one
course can be taken by many students. So the cardinality will be n to 1. It means that for one
course there can be n students but for one student, there will be only one course.
Using
Sets, it can be represented as:
In this case, each student is taking only 1 course but 1 course has been taken by many
students.
many to many: When entities in all entity sets can take part more than once in the
relationship cardinality is many to many. Let us assume that a student can take more than
one course and one course can be taken by many students. So the relationship will be many to
many.
Data structure
1. Data structure & classification
2. Linked list & classification
3. Array & classification
4. Prefix\Infix\Postfix
5. Preorder\Inorder\Postorder
6. BFS\DFS\Stack\Quee
7. Complexity analysis
8. Asymptotic Notation
9. Tree\Binary Tree\Complete Tree\Extended Tree\Full Tree
10. Expression Convertion
A data structure is a specialized format for organizing and storing data. General data structure types
include the array, the file, the record, the table, the tree, and so on. Any data structure is designed
to organize data to suit a specific purpose so that it can be accessed and worked with in appropriate
ways.
Based on the organizing method of a data structure, data structures are divided into two types.
If a data structure is organizing the data in sequential order, then that data structure is called
as Linear Data Structure.
Example
1. Arrays
2. List (Linked List)
3. Stack
4. Queue
If a data structure is organizing the data in random order, then that data structure is called as
Non-Linear Data Structure.
Example
1. Tree
2. Graph
3. Dictionaries
4. Heaps
5. Tries, Etc.,
A linked list is a linear data structure where each element is a separate object.
Each element (we will call it a node) of a list is comprising of two items - the data and a
reference to the next node. The last node has a reference to null. The entry point into a linked
list is called the head of the list. It should be noted that head is not a separate node, but the
reference to the first node. If the list is empty then the head is a null reference.
Single linked list is a sequence of elements in which every element has link to its next
element in the sequenc
1. Insertion
2. Deletion
3. Display
1. Insertion
2. Deletion
3. Display
What is stack?
What is queue?
Breadth-first search (BFS) is an algorithm for traversing or searching tree or graph data structures. It
starts at the tree root (or some arbitrary node of a graph, sometimes referred to as a 'search key')
and explores the neighbor nodes first, before moving to the next level neighbors.
Depth-first search (DFS) is an algorithm for traversing or searching tree or graph data structures.
One starts at the root (selecting some arbitrary node as the root in the case of a graph) and explores
as far as possible along each branch before backtracking.
What is binary tree?
A binary tree is a tree data structure in which each node has at most two children, which are
referred to as the left child and the right child
A full binary tree (sometimes proper binary tree or 2-tree) is a tree in which every node other than
the leaves has two children.
A binary tree can be converted into Full Binary tree by adding dummy nodes to existing
nodes wherever required.
The full binary tree obtained by adding dummy nodes to a binary tree is called as Extended
Binary Tree.
In above figure, a normal binary tree is converted into full binary tree by adding dummy
nodes (In pink colour
A complete binary tree is a binary tree in which every level, except possibly the last, is completely
filled, and all nodes are as far left as possible.
What is Array?
An array is a variable which can store multiple values of same data type at a time.
Linear data structures are in which all the data are arranged in sequence manner.for example:linked
list,stack queue.
Non linear data structure are in which all the data are arranged in random manner.for example
:trees,graphs.
A complete binary tree is a binary tree in which every level, except possibly the last, is completely
filled, and all nodes are as far left as possible.
Space complexity is a measure of the amount of working storage an algorithm needs. That means
how much memory, in the worst case, is needed at any point in the algorithm.
What is time complexity? The time complexity of an algorithm quantifies the amount of time
taken by an algorithm to run as a function of the length of the string representing the input. The
time complexity of an algorithm is commonly expressed using big O notation, which excludes
coefficients and lower order terms.
Asymptotic Notations are languages that allow us to analyze an algorithm's running time by
identifying its behavior as the input size for the algorithm increases. This is also known as an
algorithm's growth rate.
What is Postfix Notation? Postfix notation is a notation for writing arithmetic expressions in
which the operands appear before their operators. Using Stacks. Homework #5. Postfix notation is a
notation for writing arithmetic expressions in which the operands appear before their operators.
Infix notation is the notation commonly used in arithmetical and logical formulae and statements. It
is characterized by the placement of operators between operands – "infixed operators" – such as the
plus sign in "2 + 2".
Reverse Polish notation (RPN) is a mathematical notation in which every operator follows all of its
operands, in contrast to Polish notation (PN), which puts the operator before its operands. It is also
known as postfix notation. It does not need any parentheses as long as each operator has a fixed
number of operands.
Example
1. Read all the symbols one by one from left to right in the given Postfix Expression
2. If the reading symbol is operand, then push it on to the Stack.
3. If the reading symbol is operator (+ , - , * , / etc.,), then perform TWO pop
operations and store the two popped oparands in two different variables
(operand1 and operand2). Then perform reading symbol operation using
operand1 and operand2 and push result back on to the Stack.
4. Finally! perform a pop operation and display the popped value as final result.
Example
Consider the following Expression...
Expression Conversion:
Any expression can be represented using three types of expressions (Infix, Postfix and
Prefix). We can also convert one type of expression to another type of expression like Infix to
Postfix, Infix to Prefix, Postfix to Prefix and vice versa.
To convert any Infix expression into Postfix or Prefix expression we can use the following
procedure...
Example
Consider the following Infix Expression to be converted into Postfix Expression...
D=A+B*C
DABC*+=
1. Read all the symbols one by one from left to right in the given Infix Expression.
2. If the reading symbol is operand, then directly print it to the result (Output).
3. If the reading symbol is left parenthesis '(', then Push it on to the Stack.
4. If the reading symbol is right parenthesis ')', then Pop all the contents of stack
until respective left parenthesis is poped and print each poped symbol to the
result.
5. If the reading symbol is operator (+ , - , * , / etc.,), then Push it on to the Stack.
However, first pop the operators which are already on the stack that have higher
or equal precedence than current operator and print them to the result.
Example
Consider the following Infix Expression...
(A+B)*(C-D)
The given infix expression can be converted into postfix expression using Stack data
Structure as follows...
Infix notation needs extra information to make the order of evaluation of the operators
clear: rules built into the language about operator precedence and associativity, and
brackets ( ) to allow users to override these rules. For example, the usual rules for
associativity say that we perform operations from left to right, so the multiplication by
A is assumed to come before the division by D. Similarly, the usual rules for
precedence say that we perform multiplication and division before we perform
addition and subtraction. (see CS2121 lecture).
( (A (B C +) *) D /)
Thus, the "*" uses the two values immediately preceding: "A", and the result of the
addition. Similarly, the "/" uses the result of the multiplication and the "D".
Prefix notation (also known as "Polish notation"): + X Y
Operators are written before their operands. The expressions given above are
equivalent to / * A + B C D
As for Postfix, operators are evaluated left-to-right and brackets are superfluous.
Operators act on the two nearest values on the right. I have again added (totally
unnecessary) brackets to make this clear:
(/ (* A (+ B C) ) D)
Although Prefix "operators are evaluated left-to-right", they use values to their right,
and if these values themselves involve computations then this changes the order that
the operators have to be evaluated in. In the example above, although the division is
the first operator on the left, it acts on the result of the multiplication, and so the
multiplication has to happen before the division (and similarly the addition has to
happen before the multiplication).
Because Postfix operators use values to their left, any values involving computations
will already have been calculated as we go left-to-right, and so the order of evaluation
of the operators is not disrupted in the same way as in Prefix expressions.
In all three versions, the operands occur in the same order, and just the operators have to be
moved to keep the meaning correct. (This is particularly important for asymmetric operators
like subtraction and division: A - B does not mean the same as B - A; the former is
equivalent to A B - or - A B, the latter to B A - or - B A).
Examples:
You can use a similar trick to convert to and from parse trees - each bracketed triplet of an
operator and its two operands (or sub-expressions) corresponds to a node of the tree. The
corresponding parse trees are:
/ *
+ / \ / \
/ \ * D A +
/ \ / \ / \
* / A + B /
/ \ / \ / \ / \
A B C D B C C D
Expression Conversion:
Any expression can be represented using three types of expressions (Infix, Postfix and
Prefix).We can also convert one type of expression to another type of expression like Infix to
Postfix, Infix to Prefix, Postfix to Prefix and vice versa.
To convert any Infix expression into Postfix or Prefix expression we can use the following
procedure...
Example
Consider the following Infix Expression to be converted into Postfix Expression...
D=A+B*C
DABC*+=
1. Read all the symbols one by one from left to right in the given Infix Expression.
2. If the reading symbol is operand, then directly print it to the result (Output).
3. If the reading symbol is left parenthesis '(', then Push it on to the Stack.
4. If the reading symbol is right parenthesis ')', then Pop all the contents of stack
until respective left parenthesis is poped and print each poped symbol to the
result.
5. If the reading symbol is operator (+ , - , * , / etc.,), then Push it on to the Stack.
However, first pop the operators which are already on the stack that have higher
or equal precedence than current operator and print them to the result.
Example
Consider the following Infix Expression...
(A+B)*(C-D)
The given infix expression can be converted into postfix expression using Stack data
Structure as follows...
The final Postfix Expression is as follows...
AB+CD-*
AB+CD-*
Security
1. Antivirus
2. Firewall & Types of firewall
3. DOS\DDOS
4. DOS Attack
5. Phishing
6. Pharming
7. Session hijacking
8. Password Policy
What Is Anti-Virus?
Anti-virus is a security program you install on your computer or mobile device to protect it from
getting infected by malware.
Or, Antivirus software often referred to as antivirus or AV is a software program (or a set of
programs) designed to search for, detect, block and remove malicious software- viruses, trojans,
worms, adware etc.
6. Comodo Antivirus
9. Malwarebytes
DDoS is a type of DOS attack where multiple compromised systems, which are often infected with a
Trojan, are used to target a single system causing a Denial of Service (DoS) attack.
A Distributed Denial of Service (DDoS) attack is an attempt to make an online service unavailable by
overwhelming it with traffic from multiple sources
What is Phishing?
Phishing is a cybercrime in which a target or targets are contacted by email, telephone or text
message by someone posing as a legitimate institution to lure individuals into providing
sensitive data such as personally identifiable information, banking and credit card details, and
passwords.
In computer science, session hijacking, sometimes also known as cookie hijacking is the exploitation
of a valid computer session—sometimes also called a session key—to gain unauthorized access to
information or services in a computer system.
What is Pharming?
Pharming is a scamming practice in which malicious code is installed on a personal
computer or server, misdirecting users to fraudulent Web sites without their knowledge or
consent. Pharming has been called "phishing without a lure
As we’ve seen earlier, the method often used to steal session id is by installing a malicious
code on the client website and then the cookie is stealing. The best way to prevent session
hijacking is enabling the protection from the client side. It is recommended that taking
preventive measures for the session hijacking on the client side. The users should have
efficient antivirus, anti-malware software, and should keep the software up to date.
There is a technique that uses engines which fingerprints all requests of a session. In addition
to tracking the IP address and SSL session id, the engines also track the http headers. Each
change in the header adds penalty points to the session and the session gets terminated as
soon as the points exceeds a certain limit. This limit can be configured. This is effective
because when intrusion occurs, it will have a different http header order.
These are the recommended preventive measures to be taken from both the client and server
sides in order to prevent the session hijacking attack.
To use SSL/HTTPS encryption for the entire web site, and you have the best guarantee that
no man in the middle attacks will be able to sniff an existing client session cookie?
To use some sort of encryption on the session value itself that is stored in your session
cookie?
Encrypting the session value will have zero effect. The session cookie is already an arbitrary
value, encrypting it will just generate another arbitrary value that can be sniffed.
The only real solution is HTTPS. first make sure your login page is HTTPS. When a user logs in,
set a secure cookie (meaning the browser will only transmit it over an SSL link) in addition to
the regular session cookie. Then, when a user visits one of your "sensitive" areas, redirect
them to HTTPS, and check for the presence of that secure cookie. A real user will have it, a
session hijacker will not.
HTTPS will prevent the sniffing only. But if you have a XSS, or the session IDs can be guessed
easily, or you are vulnerable to session fixation, or your session ID storage is weak (SQL
injection?),
The SSL only helps with sniffing attacks. If an attacker has access to your machine I will
assume they can copy your secure cookie too.
A password policy is a set of rules designed to enhance computer security by encouraging users
to employ strong passwords and use them properly. A password policy is often part of an
organization's official regulations and may be taught as part of security awareness training.
Bank Related IT
MICR is an acronym for Magnetic Ink Character Recognition; it refers to the formulation of
toner used to print the specialized font at the bottom of checks and other negotiable
documents.
RTGS (real time gross settlement) and NEFT (national electronic funds transfer) are
electronic payment systems that allow individuals to transfer funds between banks. Both
these systems are maintained by the Reserve Bank of India. It is applicable only for money
transfer within the country.
Agent Banking means providing limited scale banking and financial services to the
underserved population through engaged agents under a valid agency agreement, rather
than a teller/ cashier. It is the owner of an outlet who conducts banking transactions on
behalf of a bank.
Electronic banking, also known as electronic funds transfer (EFT), is simply the use of
electronic means to transfer funds directly from one account to another, rather than by check
or cash. You can use electronic funds transfer to: have your paycheck deposited directly into
your bank or credit union checking account.
An electronic funds transfer (EFT) is a transaction that takes place over a computerized
network, either among accounts at the same bank or to different accounts at separate financial
institutions.
What is a POS?
A retail point of sale system typically includes a cash register (which in recent times
comprises a computer, monitor, cash drawer, receipt printer, customer display and a barcode
scanner) and the majority of retail POS systems also include a debit/credit card reader.
POS stands for Point Of Sale. This is a rather broad definition that can include
merchandising aids, displays and the methods used to enable transactions. ... The heart of any
POS system is the computer (or computers) that runs the POS software.
ATM stands for Automated Teller Machine. It's a specialized computer that makes it
convenient to manage your money. For example, almost all ATMs allow you to withdraw
money, and many allow you to make deposits.
Mobile banking refers to the use of a smartphone or other cellular device to perform online
banking tasks while away from your home computer, such as monitoring account balances,
transferring funds between accounts, bill payment and locating an ATM.
Plastic money is a term that is used predominantly in reference to the hard plastic cards we
use everyday in place of actual bank notes. They can come in many different forms such as
cash cards, credit cards, debit cards, pre-paid cash cards and store cards.
Credit Card is a small plastic card issued by a bank, business, etc., allowing the holder to
purchase goods or services on credit.
A debit card (also known as a bank card or check card) is a plastic payment card that can be
used instead of cash when making purchases. It is similar to a credit card, but unlike a credit card,
the money comes directly from the user's bank account when performing a transaction.