This document provides an overview of data structures and algorithms concepts through a presentation. It begins with an introduction to outcome based education and accreditation standards. It then covers Bloom's taxonomy, vision/mission statements, and defines key terms like program outcomes, course outcomes, and mappings between them. Several data structures are defined, like stacks, queues, and linked lists. Algorithms topics covered include recursion, sorting, searching and complexity analysis. Specific course details are provided like learning objectives, syllabus, and outcome mappings.
Outcome Based Education (OBE) - A practitioner's experienceRavindra Dastikop
In this webinar the presenter shares his experience of designing , developing and delivering an engineering course based on the principles of OBE. The webinar has two parts. In the first part, it will discuss the experience gained in delivering a OBE enabled course and the second part demonstrates how to implement the course on a cloud-based system that supports the entire life-cycle of implementing OBE process
WILMINGTON UNIVERSITYCOLLEGE OF TECHNOLOGYSYLLABUSFACULTY ME.docxambersalomon88660
WILMINGTON UNIVERSITY
COLLEGE OF TECHNOLOGYSYLLABUS
FACULTY MEMBER: Greg Hughes TERM: Summer 2016 Block 2
COURSE TITLE: IT Policy & Strategy
COURSE NUMBER: IST.7100
TEXTBOOK: TITLE:
AUTHOR:
If you would like more precise information regarding the textbook(s) for this class, please visit the bookstore website at http://www.wilmcoll.edu/bookstore
METHOD OF CONTACT:
PREREQUISITE: IST7000, IST7020, IST7040, IST7060
All courses are open to students from all divisions. Only where a course is preceded by an introduction course is there a need to observe a prerequisite. However, students might benefit from prior knowledge on some of the courses, and this is given as the content found in your course catalogue by course code.
I. COURSE DESCRIPTION
The focus of this course includes: 1) The top management’s strategic perspective for aligning competitive strategy, core competencies, and information systems; 2) The development and implementation of policies and plans to achieve organizational goals; 3) Defining the systems that support the operational, administrative, and strategic needs of the organization, its business units, and individual employees; 4) Approaches to managing the information systems’ function in organizations, including examination of the dual challenges of effectively controlling the use of well-established information technologies, while experimenting with selected emerging technologies; and 5) The role of the CIO.
II. RATIONALE
Students develop an understanding of the strategic use of information technology from a business perspective at the enterprise level. They are expected to understand the internal management of information systems services from the point of view of the CIO and to examine alternative strategies and tactics available to management to achieve goals. Working students and students with post-baccalaureate experience will be able to examine the current and potential impact of information and information technology on all aspects of their position, firm, and industry.
III. MAJOR INSTRUCTIONAL GOALS
Goal A. Understand the role of IT in reaching business objectives
Learning Outcomes: The student will be able to:
A-1 Differentiate between strategy, vision and strategic objectives
A-2 Differentiate between effective business strategies based on a company’s vision, strategy, and mission statements
A-3 Identify the significance of the five levels of Strategic Alignment Maturity
A-4 Identify the primary differences between strategic, tactical and operational processes
Goal B. Understand the role of governance and communication in the selection and use of organizational processes to make decisions about how to obtain and deploy IT resources
Learning Outcome:The student will be able to:
B-1 Understand the components of a strategic plan
B-2 Identify organizational types and use in case study application
B-3 Identify the components of IT architecture
B-4 Identify .
Prepare the following documents and develop the software project startup, prototype
model, using software engineering methodology for at least two real time scenarios or
for the sample experiments
Outcome Based Education (OBE) - A practitioner's experienceRavindra Dastikop
In this webinar the presenter shares his experience of designing , developing and delivering an engineering course based on the principles of OBE. The webinar has two parts. In the first part, it will discuss the experience gained in delivering a OBE enabled course and the second part demonstrates how to implement the course on a cloud-based system that supports the entire life-cycle of implementing OBE process
WILMINGTON UNIVERSITYCOLLEGE OF TECHNOLOGYSYLLABUSFACULTY ME.docxambersalomon88660
WILMINGTON UNIVERSITY
COLLEGE OF TECHNOLOGYSYLLABUS
FACULTY MEMBER: Greg Hughes TERM: Summer 2016 Block 2
COURSE TITLE: IT Policy & Strategy
COURSE NUMBER: IST.7100
TEXTBOOK: TITLE:
AUTHOR:
If you would like more precise information regarding the textbook(s) for this class, please visit the bookstore website at http://www.wilmcoll.edu/bookstore
METHOD OF CONTACT:
PREREQUISITE: IST7000, IST7020, IST7040, IST7060
All courses are open to students from all divisions. Only where a course is preceded by an introduction course is there a need to observe a prerequisite. However, students might benefit from prior knowledge on some of the courses, and this is given as the content found in your course catalogue by course code.
I. COURSE DESCRIPTION
The focus of this course includes: 1) The top management’s strategic perspective for aligning competitive strategy, core competencies, and information systems; 2) The development and implementation of policies and plans to achieve organizational goals; 3) Defining the systems that support the operational, administrative, and strategic needs of the organization, its business units, and individual employees; 4) Approaches to managing the information systems’ function in organizations, including examination of the dual challenges of effectively controlling the use of well-established information technologies, while experimenting with selected emerging technologies; and 5) The role of the CIO.
II. RATIONALE
Students develop an understanding of the strategic use of information technology from a business perspective at the enterprise level. They are expected to understand the internal management of information systems services from the point of view of the CIO and to examine alternative strategies and tactics available to management to achieve goals. Working students and students with post-baccalaureate experience will be able to examine the current and potential impact of information and information technology on all aspects of their position, firm, and industry.
III. MAJOR INSTRUCTIONAL GOALS
Goal A. Understand the role of IT in reaching business objectives
Learning Outcomes: The student will be able to:
A-1 Differentiate between strategy, vision and strategic objectives
A-2 Differentiate between effective business strategies based on a company’s vision, strategy, and mission statements
A-3 Identify the significance of the five levels of Strategic Alignment Maturity
A-4 Identify the primary differences between strategic, tactical and operational processes
Goal B. Understand the role of governance and communication in the selection and use of organizational processes to make decisions about how to obtain and deploy IT resources
Learning Outcome:The student will be able to:
B-1 Understand the components of a strategic plan
B-2 Identify organizational types and use in case study application
B-3 Identify the components of IT architecture
B-4 Identify .
Prepare the following documents and develop the software project startup, prototype
model, using software engineering methodology for at least two real time scenarios or
for the sample experiments
Francesca Gottschalk - How can education support child empowerment.pptxEduSkills OECD
Francesca Gottschalk from the OECD’s Centre for Educational Research and Innovation presents at the Ask an Expert Webinar: How can education support child empowerment?
Honest Reviews of Tim Han LMA Course Program.pptxtimhan337
Personal development courses are widely available today, with each one promising life-changing outcomes. Tim Han’s Life Mastery Achievers (LMA) Course has drawn a lot of interest. In addition to offering my frank assessment of Success Insider’s LMA Course, this piece examines the course’s effects via a variety of Tim Han LMA course reviews and Success Insider comments.
Acetabularia Information For Class 9 .docxvaibhavrinwa19
Acetabularia acetabulum is a single-celled green alga that in its vegetative state is morphologically differentiated into a basal rhizoid and an axially elongated stalk, which bears whorls of branching hairs. The single diploid nucleus resides in the rhizoid.
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...Levi Shapiro
Letter from the Congress of the United States regarding Anti-Semitism sent June 3rd to MIT President Sally Kornbluth, MIT Corp Chair, Mark Gorenberg
Dear Dr. Kornbluth and Mr. Gorenberg,
The US House of Representatives is deeply concerned by ongoing and pervasive acts of antisemitic
harassment and intimidation at the Massachusetts Institute of Technology (MIT). Failing to act decisively to ensure a safe learning environment for all students would be a grave dereliction of your responsibilities as President of MIT and Chair of the MIT Corporation.
This Congress will not stand idly by and allow an environment hostile to Jewish students to persist. The House believes that your institution is in violation of Title VI of the Civil Rights Act, and the inability or
unwillingness to rectify this violation through action requires accountability.
Postsecondary education is a unique opportunity for students to learn and have their ideas and beliefs challenged. However, universities receiving hundreds of millions of federal funds annually have denied
students that opportunity and have been hijacked to become venues for the promotion of terrorism, antisemitic harassment and intimidation, unlawful encampments, and in some cases, assaults and riots.
The House of Representatives will not countenance the use of federal funds to indoctrinate students into hateful, antisemitic, anti-American supporters of terrorism. Investigations into campus antisemitism by the Committee on Education and the Workforce and the Committee on Ways and Means have been expanded into a Congress-wide probe across all relevant jurisdictions to address this national crisis. The undersigned Committees will conduct oversight into the use of federal funds at MIT and its learning environment under authorities granted to each Committee.
• The Committee on Education and the Workforce has been investigating your institution since December 7, 2023. The Committee has broad jurisdiction over postsecondary education, including its compliance with Title VI of the Civil Rights Act, campus safety concerns over disruptions to the learning environment, and the awarding of federal student aid under the Higher Education Act.
• The Committee on Oversight and Accountability is investigating the sources of funding and other support flowing to groups espousing pro-Hamas propaganda and engaged in antisemitic harassment and intimidation of students. The Committee on Oversight and Accountability is the principal oversight committee of the US House of Representatives and has broad authority to investigate “any matter” at “any time” under House Rule X.
• The Committee on Ways and Means has been investigating several universities since November 15, 2023, when the Committee held a hearing entitled From Ivory Towers to Dark Corners: Investigating the Nexus Between Antisemitism, Tax-Exempt Universities, and Terror Financing. The Committee followed the hearing with letters to those institutions on January 10, 202
Biological screening of herbal drugs: Introduction and Need for
Phyto-Pharmacological Screening, New Strategies for evaluating
Natural Products, In vitro evaluation techniques for Antioxidants, Antimicrobial and Anticancer drugs. In vivo evaluation techniques
for Anti-inflammatory, Antiulcer, Anticancer, Wound healing, Antidiabetic, Hepatoprotective, Cardio protective, Diuretics and
Antifertility, Toxicity studies as per OECD guidelines
Operation “Blue Star” is the only event in the history of Independent India where the state went into war with its own people. Even after about 40 years it is not clear if it was culmination of states anger over people of the region, a political game of power or start of dictatorial chapter in the democratic setup.
The people of Punjab felt alienated from main stream due to denial of their just demands during a long democratic struggle since independence. As it happen all over the word, it led to militant struggle with great loss of lives of military, police and civilian personnel. Killing of Indira Gandhi and massacre of innocent Sikhs in Delhi and other India cities was also associated with this movement.
The Roman Empire A Historical Colossus.pdfkaushalkr1407
The Roman Empire, a vast and enduring power, stands as one of history's most remarkable civilizations, leaving an indelible imprint on the world. It emerged from the Roman Republic, transitioning into an imperial powerhouse under the leadership of Augustus Caesar in 27 BCE. This transformation marked the beginning of an era defined by unprecedented territorial expansion, architectural marvels, and profound cultural influence.
The empire's roots lie in the city of Rome, founded, according to legend, by Romulus in 753 BCE. Over centuries, Rome evolved from a small settlement to a formidable republic, characterized by a complex political system with elected officials and checks on power. However, internal strife, class conflicts, and military ambitions paved the way for the end of the Republic. Julius Caesar’s dictatorship and subsequent assassination in 44 BCE created a power vacuum, leading to a civil war. Octavian, later Augustus, emerged victorious, heralding the Roman Empire’s birth.
Under Augustus, the empire experienced the Pax Romana, a 200-year period of relative peace and stability. Augustus reformed the military, established efficient administrative systems, and initiated grand construction projects. The empire's borders expanded, encompassing territories from Britain to Egypt and from Spain to the Euphrates. Roman legions, renowned for their discipline and engineering prowess, secured and maintained these vast territories, building roads, fortifications, and cities that facilitated control and integration.
The Roman Empire’s society was hierarchical, with a rigid class system. At the top were the patricians, wealthy elites who held significant political power. Below them were the plebeians, free citizens with limited political influence, and the vast numbers of slaves who formed the backbone of the economy. The family unit was central, governed by the paterfamilias, the male head who held absolute authority.
Culturally, the Romans were eclectic, absorbing and adapting elements from the civilizations they encountered, particularly the Greeks. Roman art, literature, and philosophy reflected this synthesis, creating a rich cultural tapestry. Latin, the Roman language, became the lingua franca of the Western world, influencing numerous modern languages.
Roman architecture and engineering achievements were monumental. They perfected the arch, vault, and dome, constructing enduring structures like the Colosseum, Pantheon, and aqueducts. These engineering marvels not only showcased Roman ingenuity but also served practical purposes, from public entertainment to water supply.
Synthetic Fiber Construction in lab .pptxPavel ( NSTU)
Synthetic fiber production is a fascinating and complex field that blends chemistry, engineering, and environmental science. By understanding these aspects, students can gain a comprehensive view of synthetic fiber production, its impact on society and the environment, and the potential for future innovations. Synthetic fibers play a crucial role in modern society, impacting various aspects of daily life, industry, and the environment. ynthetic fibers are integral to modern life, offering a range of benefits from cost-effectiveness and versatility to innovative applications and performance characteristics. While they pose environmental challenges, ongoing research and development aim to create more sustainable and eco-friendly alternatives. Understanding the importance of synthetic fibers helps in appreciating their role in the economy, industry, and daily life, while also emphasizing the need for sustainable practices and innovation.
Read| The latest issue of The Challenger is here! We are thrilled to announce that our school paper has qualified for the NATIONAL SCHOOLS PRESS CONFERENCE (NSPC) 2024. Thank you for your unwavering support and trust. Dive into the stories that made us stand out!
Embracing GenAI - A Strategic ImperativePeter Windle
Artificial Intelligence (AI) technologies such as Generative AI, Image Generators and Large Language Models have had a dramatic impact on teaching, learning and assessment over the past 18 months. The most immediate threat AI posed was to Academic Integrity with Higher Education Institutes (HEIs) focusing their efforts on combating the use of GenAI in assessment. Guidelines were developed for staff and students, policies put in place too. Innovative educators have forged paths in the use of Generative AI for teaching, learning and assessments leading to pockets of transformation springing up across HEIs, often with little or no top-down guidance, support or direction.
This Gasta posits a strategic approach to integrating AI into HEIs to prepare staff, students and the curriculum for an evolving world and workplace. We will highlight the advantages of working with these technologies beyond the realm of teaching, learning and assessment by considering prompt engineering skills, industry impact, curriculum changes, and the need for staff upskilling. In contrast, not engaging strategically with Generative AI poses risks, including falling behind peers, missed opportunities and failing to ensure our graduates remain employable. The rapid evolution of AI technologies necessitates a proactive and strategic approach if we are to remain relevant.
2. Presentation on Awareness of
Outcome Based Education (OBE)
and
National Board of Accreditation(NBA)
Department of Master of Computer Applications
Bangalore Institute of Technology
3. Overview
2. Bloom’s Taxonomy of Learning
3
3. Outcome Based Education (OBE)
4. Vision and Mission of the Institute
5. Vision and Mission of the Department
6. Program Educational Objectives (PEO’s)
8. Course Learning Objectives (CLO’s)
7. Program Outcomes (PO’s)
9.Course Outcomes (CO’s)
1. National Board of Accreditation (NBA)
4. National Board of Accreditation – Washington
Accord (NBA – WA)
Washington Accord – (ABET – US) : ABET accreditation
provides assurance that a college or university program
meets the quality standards of the profession for which that
program prepares its graduates.
Promoting international quality standards for technical
education in India
Recognition by stakeholders (Students, Faculty, Support
Staff, Industry and Employers, Parents, Government, and
Society)
Washington accord: India a signatory nation
Recognition of graduates globally
4
5. Why is accreditation important?
Accreditation helps prospective students and their
parents choose quality college programmes
Accreditation enables employers to recruit graduates they
know are well prepared.
Accreditation gives colleges and universities a structured
mechanism to assess, evaluate and improve the quality of
their programmes.
Accreditation benefits society as a whole.
5
9. 9
What Is Outcome Based Education?
Outcome based education is student centered
instruction that focuses on measuring
student performance i.e. outcomes.
Outcomes include knowledge skills and
attitudes
Outcome based accreditation – focus remains
on evaluation of outcomes of the program,
though input and output parameters are also
important
10. 10
What Is Outcome Based Education?
Students are expected to be able to do more challenging tasks other
than memorize and reproduce what was taught.
Students should be able to: write project proposals, complete
projects, analyze case studies, give case presentations, show
their abilities to think, question, research, and make decisions
based on the findings.
Be more creative, able to analyze and synthesize information.
Able to plan and organize tasks, able to work in a team as a
community or in entrepreneurial service teams to propose solutions
to problems and market their solutions
11. 11
It’s not what Teachers teach, It’s more of what
students LEARN
In a nutshell, learner-centric approach to education
What Is Outcome Based Education?
NO OBE = NO ACCREDITATION
Starting with a clear picture of what is important for
students to be able to do…
Then organizing the curriculum, delivery and assessment
to make sure learning happens…
13. Vision and Mission of the Institute
Vision of the Institute
To establish and develop the Institute as a centre
of higher learning, ever abreast with expanding
horizon of knowledge in the field of engineering
and technology, with entrepreneurial thinking,
leadership excellence for life-long success and
solve societal problem.
13
14. Vision and Mission of the Institute
Mission of the Institute
M1. Provide high quality education in the engineering disciplines from
the undergraduate through doctoral levels with creative academic and
professional programs.
M2. Develop the Institute as a leader in Science, Engineering,
Technology and management, Research and apply knowledge for the
benefit of society.
M3. Establish mutual beneficial partnerships with industry, alumni,
local, state and central governments by public service assistance and
collaborative research.
M4. Inculcate personality development through sports, cultural and
extracurricular activities and engage in the social, economic and
professional challenges.
14
15. Vision, Mission of Department
Vision
• To transform young graduates into skilled
computer professionals to meet Industrial
and Societal needs.
16. Vision, Mission of Department
Mission
To enhance the Teaching learning process to meet quality
education in the field of Computer applications
To impart the knowledge in current technologies to meet
the industrial needs
To inculcate ethical values and leadership qualities for the
betterment of society
17. MCA Department PEOs
• PEO1: To develop quality application software with
innovative ideas to meet the industrial requirements
• PEO2: To imbibe the current technologies and to adopt in
computing profession as per the changing needs
• PEO3: To progress in their career with leadership qualities
and ethical values that enhances self and societal growth
18. Program Outcomes(POs)
The graduates will have an ability to
PO1: Apply knowledge of computing fundamentals, computing
specialization, mathematics and domain knowledge to provide IT
solutions
PO2: Identify, analyze and solve IT problems using fundamental
principles of mathematics and computing sciences
PO3: Design, Develop and evaluate software solutions to meet
societal and environmental concerns
19. Program Outcomes(POs)
The graduates will have an ability to
PO4: Conduct investigations of complex problems using research
based knowledge and methods to provide valid conclusions.
PO5: Select and apply appropriate techniques and modern tools
for complex computing activities
PO6: Understand professional ethics, cyber regulations and
responsibilities
20. Program Outcomes(POs)
The graduates will have an ability to
PO7: Involve in life-long learning for continual development as
an IT professional.
PO8: Apply and demonstrate computing and management
principles to manage projects in multidisciplinary environments
by involving in different roles
PO9: Comprehend& write effective reports and make quality
presentations.
21. Program Outcomes(POs)
The graduates will have an ability to
PO10:Understand the impact of IT solutions on socio-
environmental issues
PO11: Work collaboratively as a member or leader in
multidisciplinary teams.
PO12:Identify potential business opportunities and innovate to
create value for the society and seize that opportunity
22. Syllabus
Data Structures with Algorithms
[As per Choice Based Credit System (CBCS) scheme]
Subject Code: 20MCA11
CIE Marks: 40 SEE Marks: 60 SEE Hours: 03
Course learning objectives:
This course (20MCA11) will enable student to
• Familiarize the knowledge of various types of data structures, operations and
algorithms sorting and searching operations.
• Use the concepts of Stack, Queue, Lists, Trees, Hashing, Searching and
Sorting techniques
• Build solutions for real world problems using concepts of data structures
• Familiarize with different strategies of algorithms.
• Can apply different strategies to solve applications.
23. Syllabus
MODULE 1
Classification of Data Structures: Primitive and Non- Primitive,
Linear and Nonlinear; Data structure Operations,
Stack: Definition, Representation, Operations.
Applications: Polish and reverse polish expressions, Infix to postfix
conversion, evaluation of postfix expression, infix to prefix, postfix
to infix conversion.
24. Lab Syllabus
MODULE 1
1. Write a C program to Implement the following searching techniques
a. Linear Search b. Binary Search.
2. Write a C program to implement the following sorting algorithms
using user defined functions: a. Bubble sort (Ascending order) b.
Selection sort (Descending order).
3. Write a C Program implement STACK with the following operations
a. Push an Element on to Stack b. Pop an Element from Stack
4. Implement a Program in C for converting an Infix Expression to
Postfix Expression.
5. Implement a Program in C for evaluating an Postfix Expression.
26. Syllabus
MODULE 3
Linked List : Limitations of array implementation,
Memory Management: Static (Stack) and Dynamic (Heap) Memory
Allocation, Memory management functions. Definition, Representation,
Operations: getnode() and freenode() operations,
Types: Singly Linked List. Linked list as a data Structure, Inserting and
removing nodes from a list, Linked implementations of stacks, Header
nodes, Array implementation of lists.
27. Lab Syllabus
MODULE 3
6.
Write a C program to simulate the working of a singly linked list
providing the following operations:
a. Display & Insert
b. Delete from the beginning/end
c. Delete a given element
28. Syllabus
MODULE 4
Introduction, Fundamentals of the Analysis of Algorithm
Efficiency Notion of Algorithm, Fundamentals of Algorithmic
Problem Solving, Important Problem Types,
Analysis Framework, Asymptotic Notations and Basic
efficiency classes, Mathematical analysis of Recursive and
Non-recursive algorithms.
29. Syllabus
Module-5:
Brute Force: Selection Sort and Bubble Sort, Sequential Search,
Exhaustive search and String Matching.
Divide-and-Conquer: Mergesort, Quicksort, Binary Search, Binary tree
Traversals and related properties.
Decrease-and-Conquer: Insertion Sort, Depth First and Breadth First
Search, Topological sorting.
Greedy Technique: Prim’s Algorithm, Kruskal’s Algorithm, Dijkstra’s
Algorithm.
30. Lab Syllabus
Module-5:
7. Obtain the Topological ordering of vertices in a given graph with the
help of a c programming.
8. Check whether a given graph is connected or not using DFS method
using C programming.
9. From a given vertex in a weighted connected graph, find shortest paths
to other vertices Using Dijkstra's algorithm (C programming)
10.Find Minimum Cost Spanning Tree of a given undirected graph using
Kruskal's algorithm ( C programming)
31. Syllabus
Text Books:
1. Introduction to the Design and Analysis of Algorithms. AnanyLevitin, Pearson
Education, 2nd Edition.
2. Programming in ANSI C, Balaguruswamy, McGraw Hill Education .
3. Data Structures Using C and C++ by YedidyahLangsam and Moshe J. Augenstein
and Aaron M Tenanbanum, 2nd Edition, Pearson Education Asia, 2002.
4. Introduction to Data Structure and Algorithms with C++ by Glenn W. Rowe.
32. Course Outcomes(COs)
CO No. Statement Bloom’s
Cognitive Levels
POs
1 Ability to analyze and implement the concepts of
linear data structures like Stack, Queue and Linked
List
Understanding
Analysis,
Design
PO1,PO2,PO3
2 Ability to Compute the efficiency of algorithms in
terms of asymptotic notations for the recursive and
non-recursive algorithms.
Understanding
Applying, Designing
PO1,PO2,PO3
3 Ability to implement different strategies of Algorithms
like Brute force, Divide and conquer, Decrease and
conquer and Greedy technique.
Understanding
Applying, Designing
PO1,PO2,PO3
35. DEFINITION:
“The logical & Mathematical representation of data
in computer memory is called as Data Structure”.
OR
“A data structure is a method of storing data in
a computer so that it can be used efficiently”.
DATA STRUCTURES
36. The Data Structures mainly deal with:
•The study of how the data is organized in the
memory.
•How efficiently the data can be stored in the
memory.
•How efficiently the data can be retrieved &
manipulated.
37. The Data Structure can be divided into
Primitive
The Primitive Data Structures are data
structures that can be manipulated directly by
machine instructions.
Ex: int, float, char, double.
Non-Primitive
Non-primitive data structures cannot be
manipulated directly by machine instructions.
Ex: linear and Non linear
38. Non primitive :
Linear Data Structures :
A data structure is said to be linear if its
elements form a sequence, or, in other words, a linear list.
Example : Arrays, Stacks, Quees, lists
Non linear Data Structures :
A data structure is said to be non linear if
its elements are stored randomly in memory.
Example : Graphs, Trees, Files
39. The most commonly used operations on data structures
• Insertion / Creation
• Deletion
• Traversing
• Searching
• Sorting
• Merging.
Data Structure Operations
40. • An abstract data type is a mathematical model for data types. (
Logical Model).
• Data structure is a physical model for data types.
• In ADT data types is defined by its behavior (semantics) and
possible operations on data.
ADT – Abstract Data Types
41. Definition ( ADT ) :
• ADT is a class of objects whose logical behavior is defined by a set
of values and set of operations.
• Data structure is an implementation of a ADT.
Possible values
Functions/Modules
ADT – Abstract Data Types
Behavior
Operations
42. STACKS
Def:
A stack is a special type of data structure, where
elements are inserted from one end and elements are
deleted from the same end.
The position from where elements are inserted and
from where elements are deleted is called top of the stack.
Stack is also called as Last In First Out(LIFO) data
structures.
43. Stack operations:
1. Push( Inserting an element on top of the stack)
2. Pop(Deleting an element from top of the stack)
3. Display(Display contents of stack).
44. Push Operation:
Inserting an element into the stack is called push
operation.
Only one item is inserted at a time & item has to be
inserted only from top of the stack.
Empty Stack Stack With elements
4 4
3 3 top
2 2
1 1
0 0
top = -1
12
05
15
24
45. Inserting an element to stack : (push operation )
4 4 4 4
3 3 3 3
2 2 2 top 2
1 2 top 1 1
0 top 0 0 0
top=-1
4 top 4
top 3 3
2 2
1 1
0 0
* If we try to insert one more element it results in a “ overflow of Stack”
10
40
30
20
10
20
10
30
20
10
50
40
30
20
10
46. // C function for Push Operation.
void push() //function ---1
{
/* check for overflow of stack */
if (top == stack_size-1)
{
printf(“ stack overflow);
return;
}
top = top+1;
S[top] = item;
}
47. Pop operation:
Deleting an element from the stack is called “ Pop operation”.
Only one item is deleted from the stack and the item has
to be deleted only from top of the stack.
48. Deleting an element to stack : (pop operation )
top 4 4 4 4
3 top 3 3 3
2 2 top 2 2
1 2 1 top 1
0 0 0 0
4 4
3 3
2 2
1 1
top 0 0
top = -1
* If we try to delete one more element it results in a “ underflow of Stack”
10
40
30
20
10
20
10
30
20
10
50
40
30
20
10
49. // C function to delete an item from stack.
int pop() //function----2
{
int item_deleted;
if (top == -1)
{
printf(“ Stack Underflow “);
return 0;
}
item_deleted = S[top--];
return item_deleted;
}
50. Display stack items:
The contents of the stack are displayed from the bottom
to top.
// C function to display the contents of stack/
Void display() //function----3
{
int i;
if ( top == -1 )
{ Printf(“ stack is empty”); }
for( i=0; i<=top; i++ )
{
printf(“%d”, S[i]);
}
}
51. // C program to implement stack using arrays;
#include <stdio.h>
#include < process.h>
#define STACK_SIZE 5;
int top;
int s[10];
int item;
//function ---1
//function----2
//function----3
52. Void main()
{
int item;
int item_deleted;
int choice;
top = -1;
for( ; ; )
{
printf(“1. push, 2. pop, 3. Display, 4. Exit”);
printf(“enter the choice”);
Scanf(“%d”,&choice);
53. Switch(choice)
{
Case 1:
printf(“ Enter the item to be inserted”);
Scanf( “%d”, &item);
push();
break;
Case 2:
item_deleted = pop();
if (item_deleted == 0)
printf(“stack is empty”);
else
printf(“Item deleted= %d”, item_deleted);
break;
55. Applications of stack:
The various applications in which stacks are used are :
1.Conversion of expressions
2. Evaluation of expressions
3.recursion
56. Conversion of expressions
The sequence of operators and operands that reduces to a
single value after evaluation is called an expression.
There are three different types of expressions:
Prefix Expression:
Postfix expression:
Infix expression:
57. Infix expression:
In an expression, if an operator is in the b/w two
operands, the expression is called an infix expression.
Ex: a+b, (a-b), (a+b*c-(d*f))
Postfix expression:
In an expression, if an operator follows the two
operands ( operator comes after the two operands ) , the
expression is called “postfix expression”. It is also called as
“Suffix expression”.
Ex: ab+, ab-, (a+b*c) ab*c+
Prefix Expression:
In an expression, if an operator precede the two
operands(i.e., operator comes before the two operands), the
expression is called “Prefix Expression”.
Ex: +ab, -ab….
58. Precedence and Associativity of the operator :
•While evaluating the expressions, some expressions are given
precedence over other expression and are evaluated first and
some are evaluated later.
“ The rules that determines the order in which the
different operators are evaluated are called precedence rules
Or precedence operators”.
Ex : 6 * (2 + 3) – 5 6 * (2 + 3) – 5
6 * 5 – 5 6 * 5 – 5
30 – 5 6 * 0
25 0
59. The below table shows arithmetic operators along with
priority values,
Description Operator Priority
Exponentiation $ 6
Multiplication * 4
Division / 4
Mod % 4
Addition + 2
Substraction - 2
60. Associativity of the operator :
“ The order in which the operators with same precedence
are evaluated in an expression is called associativity of the
operator”.
In such cases the precedence rules are considered with
associativity.
The associativity can be classified into two types,
left to right associative ( left associative)
right to left associative (right associative).
61. left to right associative ( left associative) :
In an expression, if there are two or more operators
having the same priority and are evaluated from left to right ,
then the operators are called left associative operators.
Right to left associative (right associative) :
In an expression, if there are two or more operators
having the same priority and are evaluated from right to left ,
then the operators are called right associative operators.
62. The below table shows arithmetic operators along with
priority values and there associativity.
Description Operator Priority Associativity
Exponentiation $ 6 Right to left
Multiplication * 4 Left to right
Division / 4 Left to right
Mod % 4 Left to right
Addition + 2 Left to right
Subtraction - 2 Left to right
64. Now substitute the values of T4,T3,T2,T1 we get postfix
expression,
T4F+ T4 = T3E^
T3E^F + T3 = AT2+
AT2 + E^F + T2 = T1D*
A T1 D * +E^F + T1 = BC-
ABC-D*+E^F+
(( A+(B-C)*D)^E+F) = ABC-D*+E^F+
65. 2. X ^ Y ^ Z-M +N+P/Q
X ^ Y ^ Z-M +N+P/Q T1 = Y^Z YZ^
T1
X ^ T1-M +N+P/Q T2 = X^T1 XT1^
T2
T2-M +N+P/Q T3 = P/Q PQ/
T3
T2-M+N+T3 T4 = T2-M T2M-
T4
T4+N+T3 T5 = T4+N T4N+
T5
T5+T3
T5T3+
66. By substituting the values of T5,T4,T3,T2,T1 we get
postfix expression,
T5T3+ T5 = T4N+ and T3 = PQ/
T4N +PQ/+ T4 = T2M-
T2M-N+PQ/+ T2 = XT1^
XT1^M-N+PQ/+ T1 = YZ^
XYZ^^M-N+PQ/+
X ^ Y ^ Z-M +N+P/Q = XYZ^^M-N+PQ/+
67. •To write a program by using stack data structure,
Let us use two precedence function F and G. The
function F contains the precedence values of symbols on top of
the stack and function G contains the precedence values of
symbols in the input string.
Shown in below table, ( infix to postfix )
Symbols Stack precedence
“F”
Input precedence
“G”
Associativity
+ , - 2 1 Left
* , / 4 3 Left
$ or ^ 5 6 Right
Operands 8 7 Left
( 0 9 Left
) - 0 -
# -1 -
68. General procedure to convert from infix to postfix form :
Step 1 :
initialize top and stack of top
top = -1
s[++top] = ‘#’
j = 0
Step 2 :
As long as the precedence value of the symbol on top of
the stack is greater than the precedence value of the current
input symbol, pop an item from the stack and place it in the
postfix expression.
while ( F(s[top]) > G(symbol) )
{
postfix[ j++ ] = s[ top-- ]
}
69. Step 3 :
Once the condition in while loop is failed, if the
precedence of the symbol on top of the stack is not equal to
the precedence value of the current input symbol, push the
current symbol on to the stack. Otherwise , delete an item
from the stack but do not place in the postfix expression.
if ( F(s[top]) != G(symbol) )
s[++top] = symbol
else
top--;
Step 4 :
After the complete execution of step 2 and step 3, pop
remaining symbols from stack to postfix expression.
while ( s[top] != ‘#’ )
postfix[j++] = s[top--]
70. * complete trace of the algorithm :
( A + ( B – C ) * D )
Stack S[top] Symbol F(s[top]) > G(symbol) Postfix
# #
# # ( ( -1 > 9 ) push (
#( ( A ( 0 > 7 ) push A
#(A
#(
A
(
+ ( 8 > 1 ) pop A
( 0 > 1 ) push +
A
#(+ + ( ( 2 > 9 ) push ( A
#(+( ( B ( 0 > 7 ) push B A
#(+(B
#(+(
B
(
- ( 8 > 1 ) pop B
( 0 > 1 ) push -
AB
#(+(- - C ( 2 > 7 ) push C AB
#(+(-C
#(+(-
#(+(
C
-
(
) ( 8 > 0 ) pop C
( 2 > 0 ) pop –
( 0 = 0 ) pop (
Don’t place in postfix expr
ABC
ABC-
71. * complete trace of the algorithm :
( A + ( B – C ) * D )
Stack S[top] Symbol F(s[top]) > G(symbol) Postfix
#(+ + * ( 2 > 3 ) push * ABC-
#(+* * D (4 > 7) push D ABC-
#(+*D
#(+*
#(+
#(
D
*
+
(
) ( 8 > 0 ) pop D
( 4 > 0 ) pop *
( 2 > 0 ) pop +
( 0 = 0 ) pop (
Don’t place in postfix expr
ABC-D
ABC-D*
ABC-D*+
# # ABC-D*+
72. /* C function for stack precedence
int F (char symbol) //function 1
{
Switch (symbol)
{
Case ‘+’ :
Case ‘-‘ : return 2;
Case ‘*’ :
Case ‘/’ : return 4;
Case ‘^’ :
Case ‘$’ : return 5;
Case ‘(‘ : return 0;
Case ‘#’: return -1;
default : return 8;
}
}
73. /* C function for input precedence
int G (char symbol) //function 2
{
Switch (symbol)
{
Case ‘+’ :
Case ‘-’ : return 1;
Case ‘*’ :
Case ‘/’ : return 3;
Case ‘^’ :
Case ‘$’ : return 6;
Case ‘(’ : return 9;
Case ‘)’ : return 0;
default : return 7;
}
}
74. /* C function to convert from infix into postfix expression.
void infix_postfix(char infix[], char postfix[])
{ //function 3
int top; int j; int I;
char s[30]; char symbol;
top=-1; Step : 1
S[++top]= ‘#’;
j=0;
for(i=0; i<strlen(infix); i++)
{
Symbol=infix[i];
75. /* if stack precedence greater , remove symbol from
stack and place into postfix. */
while ( F(s[top]) > G(symbol) ) step : 2
{
postfix[j] = s[top--];
j++;
}
if ( F(s[top]) != G(symbol) ) step : 3
S[++top] = symbol;
else
top--;
}
76. /* pop remaining symbols and place them in
postfix expression
while ( s[top] != ’#’ ) step : 4
{
postfix[j++] = s[top--];
}
postfix[j]=’0’;
}
77. // C program to convert an infix expression to postfix
expression
# include < stdio.h>
# include < string.h >
/* include function 1, function 2, function 3. */
void main ()
{
char infix[20];
char postfix[20];
printf (“ Enter the valid infix expression”);
scanf (“ %s ”, infix );
infix_postfix ( infix, postfix);
printf (“ The postfix expression is “ );
printf (“%s”,postfix);
}
78. •To write a program by using stack data structure,
Let us use two precedence function F and G. The
function F contains the precedence values of symbols on top of
the stack and function G contains the precedence values of
symbols in the input string.
Shown in below table, ( infix to prefix )
Symbols Stack precedence
“F”
Input precedence
“G”
Associativity
+ , - 1 2 Left
* , / 3 4 Left
$ or ^ 6 5 Right
Operands 8 7 Left
( - 0 Left
) 0 9 -
# -1 - -
79. General procedure to convert from infix to postfix form :
Step 1 :
initialize top and stack of top
top = -1
s[++top] = ‘#’
j = 0.( reverse the infix expression )
Step 2 :
As long as the precedence value of the symbol on top of
the stack is greater than the precedence value of the current
input symbol, pop an item from the stack and place it in the
postfix expression.
while ( F(s[top]) > G(symbol) )
{
postfix[ j++ ] = s[ top-- ]
}
80. Step 3 :
Once the condition in while loop is failed, if the
precedence of the symbol on top of the stack is not equal to
the precedence value of the current input symbol, push the
current symbol on to the stack. Otherwise , delete an item
from the stack but do not place in the postfix expression.
if ( F(s[top]) != G(symbol) )
s[++top] = symbol
else
top--;
Step 4 :
After the execution of step 2 and step 3, pop remaining
symbols from stack to postfix expression.
while ( s[top] != ‘#’ )
postfix[j++] = s[top--]
81. * complete trace of the algorithm :
( A + ( B – C )) = ) ) C – B ( + A (
i.e., CB-A+ = +A-BC
Stack S[top] Symbol F(s[top]) > G(symbol) Postfix
# # ) -1 > 9 push ‘)’
#) ) ) 0 > 9 push ‘)’
#)) ) C 0 > 7 push ‘C’
#))C
#))
C
)
- 8 > 2 pop ‘C’
0 > 2 push ‘-’
C
#))- - B 1 > 7 push ‘B’ C
#))-B
#))-
#))
B
-
)
( 8 > 0 pop ‘B’
1 > 0 pop ‘-’
0 > 0 pop ‘)’
CB
CB-
#) ) + 0 > 2 push ‘+’ CB-
#)+ + A 1 > 7 push ‘+’ CB-
#)+A
#)+
#)
A
+
)
( 8 > 0 pop ‘A’
1 > 0 pop ‘+’
0 > 0 pop ‘)’
CB-A
CB-A+
82. /* C function for stack precedence
int F (char symbol) function 1
{
Switch (symbol)
{
Case ‘+’ :
Case ‘-‘ : return 1;
Case ‘*’ :
Case ‘/’ : return 3;
Case ‘^’ :
Case ‘$’ : return 6;
Case ‘)‘ : return 0;
Case ‘#’: return -1;
default : return 8;
}
}
83. /* C function for input precedence
int G (char symbol) function 2
{
Switch (symbol)
{
Case ‘+’ :
Case ‘-’ : return 2;
Case ‘*’ :
Case ‘/’ : return 4;
Case ‘^’ :
Case ‘$’ : return 5;
Case ‘(’ : return 0;
Case ‘)’ : return 9;
default : return 7;
}
}
84. /* C function to convert from infix into prefix expression.
void infix_prefix(char infix[], char prefix[])
{ function 3
int top; int j; int I;
char s[30]; char symbol;
top=-1; Step : 1
S[++top]= ‘#’;
j=0;
strrev ( infix );
for(i=0; I < strlen (infix); i++)
{
Symbol=infix[i];
85. /* if stack precedence greater , remove symbol from
stack and place into postfix. */
while ( F(s[top]) > G(symbol) ) step : 2
{
prefix[j] = s[top--];
j++;
}
if ( F(s[top]) != G(symbol) ) step : 3
S[++top] = symbol;
else
top--;
}
86. /* pop remaining symbols and place them in
postfix expression
while ( s[top] != ’#’ ) step : 4
{
prefix[j++] = s[top--];
}
prefix[j]=’0’;
strrev (prefix );
}
87. // C program to convert an infix expression to prefix expression
# include < stdio.h>
# include < string.h >
/* include function 1, function 2, function 3. */
void main ()
{
char infix[20];
char prefix[20];
printf (“ Enter the valid infix expression”);
scanf (“ %s ”, infix );
infix_prefix ( infix, prefix);
printf (“ The postfix expression is “ );
printf (“%s”, prefix);
}
88. Evaluation of postfix expression :
Algorithm:
Step 1 : Scan the symbol from left to right.
Step 2: If the scanned symbol is an operand, push it on
to the stack.
Step 3: If the scanned symbol is an operator, pop two
elements from the stack
The first popped element is operand 2 and the
second popped element is operand1
Op2 = s[top--];
Op1 = s[top--];
89. Step 4: perform the indicated operation.
res = op1 op op2.
Step 5: push the result on to the stack.
Step 6: Repeat the above procedure till the end of the
i/p is encountered.
90. Ex: Evaluate the following postfix expression.
ABC-D*+E$F+ infix((A+(B-C)*D)$E+F)
with the values,
A=6, B=3, C=2, D=5, E=1, F=7.
Solution:
After substituting the values
632-5*+1$7+
92. // c program to evaluate the postfix expression:
#include < stdio.h >
#include < math.h >
#include < string.h >
double compute(char symbol, double op1, double op2)
{
switch ( symbol)
{
Case ‘+’ : return op1+op2;
Case ‘-’ : return op1-op2;
Case ‘*’ : return op1*op2;
Case ‘/’ : return op1/op2;
Case ‘$’:
Case ‘^’: return pow(op1,op2);
} }
93. void main()
{
double s[20] , res , op1 , op2 ;
int top, i ;
char postfix[20] , symbol ;
top = -1;
Printf(“ enter the postfix expression”);
Scanf(“%s”, postfix);
for ( i=0; i<strlen(postfix); i++ )
{
Symbol = postfix[i];
94. if ( isdigit(symbol))
S[top++]= symbol;
else
{
op2 = s[top--];
op1 = s[top--];
res = compute(symbol, op1,op2);
S[++top] = res;
}
}
res = s[top--];
printf(“ the result is %fn”, res);
}
95. Ex; to check whether a give string is palindrome or not using
stack.
# include <stdio.h>
# include <string.h>
int is_palindrome( char str[])
{
int i, top = -1;
char s[30], stk_item;
/* push all the characters of the given string
for( i=0; i<strlen(str); i++ )
{
S[++top]= str[i];
}
96. /* check whether the string is palindrome or not.
for (i=0; i<strlen(str);i++)
{
Stk_item = s[top--];
if (str[i] != stk_item)
return 0;
}
return 1;
}
97. void main()
{
Char str[20];
printf(“enter string”);
Scanf(“%s”, str);
if (is_palindrome(str))
printf(“ the string is palindrome”);
else
printf(“ the string is not a palindrome”);
}