Hashing, Hashing Tables
Introduction
Definition:
Key: a key is a field or composite of fields that
uniquely identifies an entry in a table.
Example
Table of students in a course sorted by name
-Nam
What Is Recursion?
Recursive call A method call in which the
method being called is the same as the one
making the call
Direct recursion Recursion in which a
method directly calls itself
Indirect recu
Definition of Stack
Logical (or ADT) level: A stack is an
ordered group of homogeneous items
(elements), in which the removal and
addition of stack items can take place
only at the top of the stack.
Stacks of Coins and Bills
1
What is a Stack?
Logical (or ADT) level: A stack is an
ordered group of homogeneous items
(elements), in which the removal and
addition of stack items can take place
only
Data
The representation of information in a
manner suitable for communication or
analysis by humans or machines
Data are the nouns of the programming
world:
The objects that are manipulated
The in
List Definitions
Linear relationship Each element
except the first has a unique
predecessor, and each element except
the last has a unique successor.
Length The number of items in a list; the
length c
The Software Life Cycle
Problem analysis
Requirements elicitation
Software specification
High- and low-level design
Implementation
Testing and Verification
Delivery
Operation
Maintenance
1
Software En
CS210 Winter 2017
Assignment #5
Due date: Mar.30/2017
1.(30) Write a program to convert an infix expression to a postfix expression using a
stack.
Hint: In a postfix expression operators appear after
Assignment #4
CS210 Winter 2017
Due date: Mar. 13/2017
1.( 20 marks) The Tower of Hanoi puzzle was invented by the French mathematician Edouard
Lucas in 1883. We are given a tower of five disks (you c
Assignment #3
CS210 Fall 2017
Due date: Feb.18, 2017
1. (10)Determine the running times predicted by the detailed model of the computer and
the simplified model of the computer for each of the followi
CS110-001: Programming and Problem Solving
Fall, 2017
Assignment 1
Solution Key
Note: The original questions are in red. Answers are in black.
Section 1: Short Answer Questions (0 marks)
Q1.
Memory an
CS110-001: Programming and Problem Solving
Fall, 2017
Assignment 1
Solution Key
Note: The original questions are in red. Answers are in black.
Section 2: Programming Questions (30 marks)
Q1.
(Modified
CS110-001 Programming and Problem Solving
Assignment Three (Due on March 3, 2017)
All assignments are to be submitted to UR Courses. Please note that the due time of each assignment
is at 10:00 pm (UR
CS110 Programming and Problem Solving (Winter 2017)
Assignment One (Due on January 27, 2017)
All assignments are to be submitted to UR Courses. Please note that the due time of each
assignment is at 1
CS110 Programming and Problem Solving
Assignment Zero (Due on January 13, 2017)
Note: This is a warm-up assignment. You may get up to ONE bonus mark toward your final
grade for this assignment.
All as
CS110 Programming and Problem Solving
Assignment Two (Due on Feb 10, 2017)
All assignments are to be submitted to UR Courses. Please note that the due time of each
assignment is at 10:00 pm (UR Course
CS 350: Programming Languages Concepts (Winter 2017)
Assignment 2
Chapter 3
Review Questions (3 marks for each question - Total: 21 marks)
1. Define syntax and semantics.
Syntax: the form or structure
CS 350: Programming Languages Concepts (Winter 2017)
Assignment 1
Due Date and Time: Tue, January 31, 2017 at 11:55 PM
Chapter 1
1. (12 marks). Write an evaluation of a language you know, using the cr
CS 350: Programming Languages Concepts (Winter 2017)
Assignment 3
Problem Set Solution
Chapter 5
Problem Set (3 marks each total: 15)
Choose only 5 problems out of the 8 following problems and provide
Final Exam
Dr Malek Mouhoub
CS340 Winter 2006
Wednesday April 19 2006
Duration : 3 hours
Total : 50pts
(The question paper should be handed in with the completed examination)
Exercise 1 : Algorithm De
Data Structures and Algorithm Analysis
Instructor: Dr. Malek Mouhoub
Computer Science Department
University of Regina
Fall 2016
1
6. Algorithm Design Techniques
6. Algorithm Design Techniques
6.1 Gree
Data Structures and Algorithm Analysis
Instructor: Dr. Malek Mouhoub
Computer Science Department
University of Regina
Fall 2016
1
4. Sorting and Order-Statistics
4. Sorting and Order-Statistics
The so
Data Structures and Algorithm Analysis
Instructor: Dr. Malek Mouhoub
Computer Science Department
University of Regina
Fall 2016
1
2. Trees
2. Trees
2.1 Preliminaries
2.2 Binary trees
2.3 Binary search
Data Structures and Algorithm Analysis
Instructor: Dr. Malek Mouhoub
Computer Science Department
University of Regina
Fall 2016
1
5. Graphs and Networks
CS340
5. Graphs and Networks
Plan :
5.1 Introd
Data Structures and Algorithm Analysis
Instructor: Dr. Malek Mouhoub
Computer Science Department
University of Regina
Fall 2016
1
3. Priority Queues
3. Priority Queues
ADT Stack : LIFO.
ADT Queue :
SANKIT PATEL
CS-301
04-MAR-2017
Assignment-4
Question 1
(based on Question 7.18 in Clements)
A processor executes an instruction in the following six stages. Taken separately, the time required by
eac
Alex Dalusong
200304912
Exercise 1:
What is the worst-case running time of Djikstras algorithm when implemented with d-heaps .
Answer:
Every time the main loop executes, one vertex is extracted from t