Data Structures Types of Data Structure Data Structure Operations Examples Choosing Data Structures Data Structures in Alice.

Slides:



Advertisements
Similar presentations
Data Structures Through C
Advertisements

B+-Trees (PART 1) What is a B+ tree? Why B+ trees? Searching a B+ tree
Data Structures Michael J. Watts
InOrder Traversal Algorithm // InOrder traversal algorithm inOrder(TreeNode n) { if (n != null) { inOrder(n.getLeft()); visit(n) inOrder(n.getRight());
Lecture - 1 on Data Structures. Prepared by, Jesmin Akhter, Lecturer, IIT,JU Data Type and Data Structure Data type Set of possible values for variables.
Queues Chapter 6. Chapter Objectives  To learn how to represent a waiting line (queue) and how to use the methods in the Queue interface for insertion.
Introduction to Data Structure, Spring 2007 Slide- 1 California State University, Fresno Introduction to Data Structure Introduction of Concepts Ming Li.
CS 104 Introduction to Computer Science and Graphics Problems Data Structure & Algorithms (4) Data Structures 11/18/2008 Yang Song.
Chapter 12 C Data Structures Acknowledgment The notes are adapted from those provided by Deitel & Associates, Inc. and Pearson Education Inc.
B + -Trees (Part 1). Motivation AVL tree with N nodes is an excellent data structure for searching, indexing, etc. –The Big-Oh analysis shows most operations.
COMP 110 Introduction to Programming Mr. Joshua Stough.
Queues Chapter 6. Chapter 6: Queues2 Chapter Objectives To learn how to represent a waiting line (queue) and how to use the methods in the Queue interface.
© Copyright 1992–2004 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Chapter 12 – Data Structures Outline 12.1Introduction.
INTRODUCTION TO DATA STRUCTURE. Topics To Be Discussed………………………. Meaning of Data Structure Classification of Data Structure Data Structure Operations.
Important Problem Types and Fundamental Data Structures
12 Abstract Data Types Foundations of Computer Science ã Cengage Learning.
C o n f i d e n t i a l Developed By Nitendra NextHome Subject Name: Data Structure Using C Title: Overview of Data Structure.
Introduction to Data Structures. Data Structures A data structure is a scheme for organizing data in the memory of a computer. Some of the more commonly.
Trees & Graphs Nell Dale & John Lewis (adaptation by Michael Goldwasser and Erin Chambers)
Indexing. Goals: Store large files Support multiple search keys Support efficient insert, delete, and range queries.
Copyright © Wondershare Software Introduction to Data Structures Prepared by: Eng. Ahmed & Mohamed Taha.
IntroductionIntroduction  Definition of B-trees  Properties  Specialization  Examples  2-3 trees  Insertion of B-tree  Remove items from B-tree.
CHAPTER 71 TREE. Binary Tree A binary tree T is a finite set of one or more nodes such that: (a) T is empty or (b) There is a specially designated node.
Chapter 12 Data Structure Associate Prof. Yuh-Shyan Chen Dept. of Computer Science and Information Engineering National Chung-Cheng University.
Introduction to Data Structures. About the document. The document is prepared by Prof. Shannon Bradshaw at Drew University. The key concepts in data structure.
Introduction to Data Structures. Definition Data structure is representation of the logical relationship existing between individual elements of data.
Chapter 6 Binary Trees. 6.1 Trees, Binary Trees, and Binary Search Trees Linked lists usually are more flexible than arrays, but it is difficult to use.
Binary Trees, Binary Search Trees RIZWAN REHMAN CENTRE FOR COMPUTER STUDIES DIBRUGARH UNIVERSITY.
Chapter 11 Heap. Overview ● The heap is a special type of binary tree. ● It may be used either as a priority queue or as a tool for sorting.
Chapter 9 (modified) Abstract Data Types and Algorithms Nell Dale John Lewis.
Data Structures Week 8 Further Data Structures The story so far  Saw some fundamental operations as well as advanced operations on arrays, stacks, and.
 DATA STRUCTURE DATA STRUCTURE  DATA STRUCTURE OPERATIONS DATA STRUCTURE OPERATIONS  BIG-O NOTATION BIG-O NOTATION  TYPES OF DATA STRUCTURE TYPES.
9-1 Abstract Data Types Abstract data type A data type whose properties (data and operations) are specified independently of any particular implementation.
COSC 2007 Data Structures II Chapter 15 External Methods.
1 Heaps and Priority Queues Starring: Min Heap Co-Starring: Max Heap.
Data Structures: Advanced Damian Gordon. Advanced Data Structure We’ll look at: – Linked Lists – Trees – Stacks – Queues.
Chapter 18: Searching and Sorting Algorithms. Objectives In this chapter, you will: Learn the various search algorithms Implement sequential and binary.
3 Data. Software And Data Data Data element – a single, meaningful unit of data. Name Social Security Number Data structure – a set of related data elements.
Elementary Data Organization. Outline  Data, Entity and Information  Primitive data types  Non primitive data Types  Data structure  Definition 
Data Structures Chapter 6. Data Structure A data structure is a representation of data and the operations allowed on that data. Examples: 1.Array 2.Record.
CSS446 Spring 2014 Nan Wang.  to study trees and binary trees  to understand how binary search trees can implement sets  to learn how red-black trees.
1 Algorithms Queues, Stacks and Records stored in Linked Lists or Arrays.
Data Structure and Algorithms
1 M I DAABO COURSE CODE: CSC 355 COURSE TITLE: Data Structures.
Computer Science: A Structured Programming Approach Using C1 Objectives ❏ To introduce the basic concepts of linked lists ❏ To introduce the basic concepts.
Chapter 9 Abstract Data Types and Algorithms Nell Dale John Lewis.
CPS120: Introduction to Computer Science Nell Dale John Lewis Abstract Data Types.
INTRODUCTION TO DATA STRUCTURES 1. DATA STRUCTURES A data structure is a scheme for organizing data in the memory of a computer. Some of the more commonly.
Nov 2, 2001CSE 373, Autumn Hash Table example marking deleted items + choice of table size.
An Introduction to Programming Using Alice Data Structures.
Mohammed I DAABO COURSE CODE: CSC 355 COURSE TITLE: Data Structures.
Data Structure By Amee Trivedi.
Chapter 12 – Data Structures
Course Developer/Writer: A. J. Ikuomola
Top 50 Data Structures Interview Questions
Program based on queue & their operations for an application
Data Structure Interview Question and Answers
Chapter 15 Lists Objectives
Data Structures Data Structure is a way of collecting and organising data in such a way that we can perform operations on these data in an effective.
Introduction to Data Structures
Introduction to Data Structure
Tree data structure.
Introduction to Data Structures
Chapter 15 Lists Objectives
Tree data structure.
Introduction to Data Structures
ITEC 2620M Introduction to Data Structures
Introduction to Data Structures
Introduction to Data Structures
Important Problem Types and Fundamental Data Structures
Presentation transcript:

Data Structures Types of Data Structure Data Structure Operations Examples Choosing Data Structures Data Structures in Alice

A data structure is a scheme for organizing data in the memory of a computer. Some of the more commonly used data structures include lists, arrays, stacks, queues, heaps, trees, and graphs. Binary Tree

The way in which the data is organized affects the performance of a program for different tasks. Computer programmers decide which data structures to use based on the nature of the data and the processes that need to be performed on that data. Back

Primitive data structure: the data structure available to compiler is called primitive data structure. Non primitive data structure: the data structure which is not available to compiler is called non primitive data structure.

LINEAR Array Stack Queue Linked list NON LINEAR Tree Graph Back

 Traversing: accessing each record exactly once so that certain items in the record may be processed.  Searching: Finding the location of the record with a given key value.  Inserting: Adding a new record to the structure.  Deleting: Removing a record from the structure. Back

A queue is an example of commonly used simple data structure. A queue has beginning and end, called the front and back of the queue. Data enters the queue at one end and leaves at the other. Because of this, data exits the queue in the same order in which it enters the queue, like people in a checkout line at a supermarket.

A binary tree is another commonly used data structure. It is organized like an upside down tree. Each spot on the tree, called a node, holds an item of data along with a left pointer and a right pointer. Binary Tree

The pointers are lined up so that the structure forms the upside down tree, with a single node at the top, called the root node, and branches increasing on the left and right as you go down the tree. By comparing the queue with the binary tree, you can see how the structure of the data affects what can be done efficiently with the data. Back

A queue is a good data structure to use for storing things that need to be kept in order, such as a set of documents waiting to be printed on a network printer..

The jobs will be printed in the order in which they are received. Most network print servers maintain such a print queue. A binary tree is a good data structure to use for searching sorted data. The middle item from the list is stored in the root node, with lesser items to the left and greater items to the right..

A search begins at the root. The computer either find the data, or moves left or right, depending on the value for which you are searching. Each move down the tree cuts the remaining data in half. Items can be located very quickly in a tree. Telephone directory assistance information is stored in a tree, so that a name and phone number can be found quickly

For some applications, a queue is the best data structure to use. For others, a binary tree is better. Programmers choose from among many data structures based on how the data will be used by the program. Back

Alice has two built-in data structures that can be used to organize data, or to create other data structures: Lists Arrays

A list is an ordered set of data. It is often used to store objects that are to be processed sequentially. A list can be used to create a queue.

An array is an indexed set of variables, such as dancer [1], dancer [2], dancer [3],… It is like a set of boxes that hold things. A list is a set of items. Back

THANK YOU Back