Evaluation of postfix expression algorithm using stacks

Algorithm for Evaluation of postfix expression

Postfix expression also known as   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.

Evaluation of postfix expression
Title – Evaluation of postfix expression

Continue reading Evaluation of postfix expression algorithm using stacks

Example Infix to postfix Conversion Using stacks

Example Infix to postfix conversion

Infix To postfix conversion example
Infix To postfix conversion example

 

In order to understand the example described below you need to be aware of the algorithm associated with this conversion which is described in the link below. Along with the algorithm, the meaning of each term along with c code is given below:- Continue reading Example Infix to postfix Conversion Using stacks

Infix to Postfix conversion using stack algorithm

Infix to postfix conversion algorithm

To understand the concept of infix to postfix conversion concept you need to know the know the meaning of the infix, prefix and postfix. Please go through this article to understand the concept better.

Infix to postfix conversion algorithm
Infix to postfix conversion algorithm
READ  Infix Prefix postfix expressions - datastructures

Before we dive in we need to be aware of a few basic concept used in this algorithm. Continue reading Infix to Postfix conversion using stack algorithm

File system Vs database systems (advantages database )

File system Vs Database systems

file system vs database system
file system vs database system

File system: In computing, a file system or filesystem is used to control how data is stored and retrieved. Without a file system, information placed in a storage medium would be one large body of data with no way to tell where one piece of information stops and the next begins. Continue reading File system Vs database systems (advantages database )

Infix Prefix postfix expressions – datastructures

Infix prefix postfix expressions

These notations are used because the prefix and postfix expressions are evaluated faster than infix expression (one used by humans) by the computer, especially in compilers. The prefix and postfix expressions do not contain parenthesis.

infix, postfix and prefix expressions
infix  prefix postfix expressions

Infix:

An infix expression is a single letter, or an operator, proceeded by an infix string and followed by another infix string.

eg: A, a*b.

Continue reading Infix Prefix postfix expressions – datastructures

Balancing of symbols using stacks – Data structures

Balancing of symbols

Given a string consisting of symbols consisting (, {, [. You have to check whether these symbols are balanced or not.

balancing of symbols
Title – balancing of symbols

Example :

  1. (a+b)-(c+d) is balanced .
  2. ((a+b) is not balanced .

Algorithm

  1. Create a stack.
  2. While (the end of character i.e ‘\0’ is not reached){
  • If the character read is not a symbol to be balanced, ignore it.
  • If it is an opening symbol i.e (, {, [, the push it into the stack.
  • If it is a closing symbol ), }. ] then pop the elements ( if the stack is empty return an error ) unless the same opening symbol is encountered else report an error.

}

3. At the end, the stack must be empty, else report an error.

Continue reading Balancing of symbols using stacks – Data structures

Types of databases and database applications – tutorial 2

Database Types and database applications

database types and applications
Database types and applications
  • Numeric and Textual Databases – Traditional database systems.
  • Multimedia Databases – store pictures, video clips, and sound images.
  • Geographic Information Systems (GIS) – store and analyze maps, weather data, and satellite images.
  • Data Warehouses and OLAP – extract and analyze useful information from very large databases for decision making .
  • Real – time and Active Databases – used in controlling industrial and manufacturing processes.

Continue reading Types of databases and database applications – tutorial 2

FOR THE NERDS