0% found this document useful (0 votes)
231 views8 pages

MCA Mini Project Documentation Tikamchand

The document describes a student project to implement stack, linked list, and queue data structures. It includes an overview of the project, the scope and advantages of each data structure, their basic operations, hardware and software specifications used, coding examples in C++ to demonstrate stack operations, and output from the project code. The project was completed by two students to study and demonstrate the various operations of stacks, linked lists, and queues using basic functions.

Uploaded by

Shripad Tanksal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
231 views8 pages

MCA Mini Project Documentation Tikamchand

The document describes a student project to implement stack, linked list, and queue data structures. It includes an overview of the project, the scope and advantages of each data structure, their basic operations, hardware and software specifications used, coding examples in C++ to demonstrate stack operations, and output from the project code. The project was completed by two students to study and demonstrate the various operations of stacks, linked lists, and queues using basic functions.

Uploaded by

Shripad Tanksal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

PUNYASHLOK AHILYADEVI HOLKAR SOLAPUR UNIVERSITY,SOLAPUR

School Of Computational Science


MCA Part I, Sem 1st

Mini Project On
Implementation of Stack, Linked List & Queue

Under the Guidance Of


Professor Faculty of Computational Science Department SUS
Dr. Anand Chavhan Sir

Presented By
Name:- Tikamchand M Pise, Roll No:- 40
Name:- Shankar O Zadbuke, Roll No:- 60

Project Analysis Report

Prepared By
Mr. Tikamchand M Pise
MR.Shankar O Zadbuke
12 Aprail, 2021

Index

Overview
The implementation of stack, linked list & Queue project that completed on dated 1 May, 2021 . The purpose of the
project was to this design to study the various operation of stack Linked List and Queue it was the basic resent
choosing this topic also we study that Queue implementation using an array ,linked list and circular linked list .
Each data structure has its own function Users can select from menu for data type selection to build a queue.
All data structure have basic queue functions as well as stack and linked list also.

Scope

Stack:-
A] In subroutine handling application, return address is stored in the stack.
B] Evaluation of expression in computer programing languages.
Any arithmetic calculation can be easily calculated, its representation either in the form of infix of postfix.
C] Prefix and postfix Interconvert ion of expression.
When we choose any arithmetical expression in the algorithm, naturally we use only infix expressions (operand1
Operator operand2).
These expressions are converted into equivalent machine instructions by the compiler using internal stack.
D] In recursive programing application. E] String reversing.
E] Parenthesis Matching etc.

Linked List:-
A] It is a dynamic data structure so we can insert as many nodes as required as run time. But array as maximum size
we cannot insert data after that maximum size.
B] There is no upper limit for the number of nodes in the link lists. We can add new nodes till the memory (RAM) is
free.
C] Insertion and Deletion in between the list as easy as compared to array.
D] Memory can be freed when nodes have to deletd.in array no concept is available to free memory.
E] Many complex application can easily be carried out by using Linked List.

Queue:-
A] Queues are used for many application in computer system basically queues are used in computer for scheduling of
resources to various applications like CPU, Printer etc.
B] In multiuser environment multiple printing jobs are given to the printer very frequently they are organize in the
form of FIFO manner in print queue and given to the printer.
C] In batch programing multiple jobs are combined into batches and the first program is executed first, the second is
executed next and so on in the sequential manner this mentioned in the queue.

Operations

Operations for Stack:-


1] PUSH 2] POP 3] PEEK 4] SIZE 5] ISFULL 6] ISEMPTY

Operations for Linked List:-


1] Simple Linked List 2] Doubly Linked List 3] Circular Linked List

Operation for Queue:-


1] ISFULL 2] ISEMPTY 3] INSERT 4] DELETE 5] SIZE
Hardware Specification
Speed GHZ : 2.0
Processer : care i3 & ++ Intel & other
Ram : 4GB
Hard disk : MB
Monitor : CRT, LCD, LED with 15.5 & + other in large size
Mouse : compatible to system

Software Specification
MS windows 10 OS
MS word for documentation
MS Power point for presentation
MS Visual studio 2010
My SQL for storing data

Coding:-
#include <stdio.h>
#include<iostream>
#include<cstdlib>
#include<malloc.h>
#include<conio.h>
using namespace std;

struct node{
int info;
struct node *next;
};
class stack
{
struct node *top;
public:
stack();
void push();
void pop();
void display();
};
stack::stack(){
top = NULL;
}

void stack::push()
{
int data;
struct node *p;
if((p=(node*)malloc(sizeof(node)))==NULL){
cout<<"Memory Exhausted";
exit(0);
}
cout<<"Enter a Number to insert:";
cin>>data;
p = new node;
p->info = data;
p->next = NULL;
if(top!=NULL){
p->next = top;
}
top = p;
cout<<"\nNew item inserted"<<endl;
}
void stack::pop(){
struct node *temp;
if(top==NULL){
cout<<"\nThe stack is Empty"<<endl;
}
else
{
temp = top;
top = top->next;
cout<<"\nThe value popped is "<<temp->info<<endl;
delete temp;
}
}
void stack::display()
{
struct node *p = top;
if(top==NULL)
{
cout<<"\nNothing to Display\n";
}
else{
cout<<"\nThe contents of Stack\n";
while(p!=NULL){
cout<<p->info<<endl;
p = p->next;
}
}
}

int main()
{
stack s;
int choice;
do
{
cout<<"\nEnter your choice:";
cout<<"\n1. PUSH\n2. POP\n3. DISPLAY\n4. EXIT\n";
cin>>choice;
switch(choice){
case 1:
s.push();
break;
case 2:
s.pop();
break;
case 3:
s.display();
break;
case 4:
exit(0);
break;
default:
cout<<"Invalid Choice";

break;
}
}
while(choice);
getch();
return 0;
}

2 :-

#include <stdio.h>
#include<iostream>
#include<cstdlib>
#include<malloc.h>
#include<conio.h>
using namespace std;
struct node
{
int info;
struct node *next;
};
class stack{
struct node *top;
public:
stack();
void push();
void pop();
void display();
};
stack::stack(){
top = NULL;
}
void stack::push()
{
int data;
struct node *p;
if((p=(node*)malloc(sizeof(node)))==NULL)
{
cout<<"Memory Exhausted";
exit(0);
}
cout<<"Enter a Number to insert:";
cin>>data;
p = new node;
p->info = data;
p->next = NULL;
if(top!=NULL){
p->next = top;
}
top = p;
cout<<"\nNew item inserted"<<endl;
}
void stack::pop(){
struct node *temp;
if(top==NULL){
cout<<"\nThe stack is Empty"<<endl;
}
else
{
temp = top;
top = top->next;
cout<<"\nThe value popped is "<<temp->info<<endl;
delete temp;
}
}
void stack::display()
{
struct node *p = top;
if(top==NULL)
{
cout<<"\nNothing to Display\n";
}
Else
{
cout<<"\nThe contents of Stack\n";
while(p!=NULL)
{
cout<<p->info<<endl;
p = p->next;
}
}
}
int main()
{
stack s;
int choice;
do
{
cout<<"\nEnter your choice:";
cout<<"\n1. PUSH\n2. POP\n3. DISPLAY\n4. EXIT\n";
cin>>choice;
switch(choice){
case 1:
s.push();
break;
case 2:
s.pop();
break;
case 3:
s.display();
break;
case 4:
exit(0);
break;
default:
cout<<"Invalid Choice";
break;
}
}
while(choice);
getch();
return 0;
}

Out Put:-

Sr.No.ContentsRemark
1Over view of project
2Scope & Advantages of Stack ,Linked List, & Queue
3Operations Of Stack ,Linked List, & Queue
4Hardware Specification
5Software Specification
6 Code Designing
7Out Put of code or Project screen shoots

You might also like