 200 Total Points ◦ 75 Points Writing Programs ◦ 60 Points Tracing Algorithms and determining results ◦ 35 Points Short Answer ◦ 30 Points Multiple Choice.

Slides:



Advertisements
Similar presentations
Chapter 9 Pointers and Dynamic Arrays. Overview 9.1 Pointers 9.2 Dynamic Arrays.
Advertisements

Review of Stacks and Queues Dr. Yingwu Zhu. Our Focus Only link-list based implementation of Stack class Won’t talk about different implementations of.
Reviews for Exam 1 Chapter 1-4 CSc 212 Data Structures, Sec FG CCNY, Fall 2010.
Chapter 4 Linked Lists. © 2005 Pearson Addison-Wesley. All rights reserved4-2 Preliminaries Options for implementing an ADT List –Array has a fixed size.
1 Pointers, Dynamic Data, and Reference Types Review on Pointers Reference Variables Dynamic Memory Allocation –The new operator –The delete operator –Dynamic.
1 Stack Data : a collection of homogeneous elements arranged in a sequence. Only the first element may be accessed Main Operations: Push : insert an element.
1 Procedural Concept The main program coordinates calls to procedures and hands over appropriate data as parameters.
C++ / G4MICE Course Session 3 Introduction to Classes Pointers and References Makefiles Standard Template Library.
Review for Midterm Chapter 1-9 CSc 212 Data Structures.
2 Preliminaries Options for implementing an ADT List Array has a fixed size Data must be shifted during insertions and deletions Linked list is able to.
 200 Total Points ◦ 74 Points Writing Programs ◦ 60 Points Tracing Algorithms and determining results ◦ 36 Points Short Answer ◦ 30 Points Multiple Choice.
Addresses in Memory When a variable is declared, enough memory to hold a value of that type is allocated for it at an unused memory location. This is.
Comp 245 Data Structures Linked Lists. An Array Based List Usually is statically allocated; may not use memory efficiently Direct access to data; faster.
Stacks. A stack is a data structure that holds a sequence of elements and stores and retrieves items in a last-in first- out manner (LIFO). This means.
Pointers OVERVIEW.
Exam Format  90 Total Points  60 Points Writing Programs  25 Points Tracing Code/Algorithms and determining results  5 Points Short Answer  Similar.
1 Recall Definition of Stack l Logical (or ADT) level: A stack is an ordered group of homogeneous items (elements), in which the removal and addition of.
Exam 1 Review CS Total Points – 60 Points Writing Programs – 20 Points Tracing Algorithms, determining results, and drawing pictures – 40 Points.
Final Exam Review CS Total Points – 60 Points Writing Programs – 50 Points Tracing Algorithms, determining results, and drawing pictures – 50.
Nyhoff, ADTs, Data Structures and Problem Solving with C++, Second Edition, © 2005 Pearson Education, Inc. All rights reserved Stacks.
Lecture 3 Classes, Structs, Enums Passing by reference and value Arrays.
Review of Stacks and Queues Dr. Yingwu Zhu. How does a Stack Work? Last-in-First-out (LIFO) data structure Adding an item Push operation Removing an item.
Lists Chapter 8. 2 Linked Lists As an ADT, a list is –finite sequence (possibly empty) of elements Operations commonly include: ConstructionAllocate &
 140 Total Points ◦ 100 Points Writing Programs ◦ 24 Points Tracing Algorithms and determining results ◦ 16 Points Short Answer  Similar to quizzes.
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.
Chapter 6 Lists Plus. What is a Class Template? A class template allows the compiler to generate multiple versions of a class type by using type parameters.
1 Data Structures and Algorithms Stacks and Queues.
1 Classes II Chapter 7 2 Introduction Continued study of –classes –data abstraction Prepare for operator overloading in next chapter Work with strings.
CS 1308 Exam 2 Review. Exam Format 110 Total Points 24 Points Short Answer 28 Points Fill in the Blank 16 Points T/F 36 Points Multiple Choice The above.
April 27, 2017 COSC Data Structures I Review & Final Exam
1 Chapter 15-1 Pointers, Dynamic Data, and Reference Types Dale/Weems.
Final Exam Review CS Total Points – 20 Points Writing Programs – 65 Points Tracing Algorithms, determining results, and drawing pictures – 50.
Exam 2 Review CS 3358 Data Structures. 90 Total Points – 50 Points Writing Programs – 25 Points Tracing Algorithms, determining results, and drawing pictures.
CS 1428 Exam I Review. Exam Format 130 Total Points – 40 Points Writing Programs – 30 Points Tracing Algorithms and determining results – 20 Points Short.
CS 1428 Final Exam Review. Exam Format 200 Total Points – 60 Points Writing Programs – 45 Points Tracing Algorithms and determining results – 20 Points.
Final Exam Review CS 3358.
CS 215 Final Review Ismail abumuhfouz Fall 2014.
Dr. Bernard Chen Ph.D. University of Central Arkansas
CS 1428 Exam I Review.
Chapter 4 Linked Lists.
CS 1428 Exam II Review.
CMSC 341 Lecture 5 Stacks, Queues
Exam 2 Review CS 3358 Data Structures.
CS 2308 Final Exam Review.
CS 2308 Exam I Review.
CS 2308 Exam II Review.
CS 2308 Exam II Review.
CS 2308 Exam II Review.
Exam 2 Review CS 3358 Data Structures.
CS 1428 Exam I Review.
Exam 1 Review CS 3358.
CS 2308 Exam I Review.
CS 1428 Exam II Review.
Lesson Objectives Aims
CS 2308 Exam I Review.
Exam 1 Review CS 3358.
Exam 2 Review CS 3358 Data Structures.
CS 2308 Exam II Review.
CS 1428 Final Exam Review.
EE 312 Software Design and Implementation I
Indirection.
CS 1428 Final Exam Review.
EE 312 Exam I Review.
EE 312 Final Exam Review.
EE 312 Software Design and Implementation I
EE 312 Exam I Review.
Pointers, Dynamic Data, and Reference Types
CS 1428 Exam I Review.
CS 2308 Final Exam Review.
EE 312 Exam I Review.
Presentation transcript:

 200 Total Points ◦ 75 Points Writing Programs ◦ 60 Points Tracing Algorithms and determining results ◦ 35 Points Short Answer ◦ 30 Points Multiple Choice  Will weigh more toward last third of course  Similar to previous exams, quizzes, and programming assignments  Point values are approximations

 Given the stack from the STL, write a function that converts a decimal number to a binary string.

 What will the EXACT output of the following program be? i nt foo = 9; int *ptr = &foo; float foo2 = 5.7; *ptr = 2; foo2 = foo - foo2; if (foo > foo2) cout << "Hello!"; else if (foo < foo2) cout << foo2; else cout << foo; cout << endl; cout << "foo2 is: " << fixed << setprecision(1) << foo2 << endl;

 Of what order of magnitude is a Bubble Sort?

 40 points ◦ One and two-dimensional arrays  Declaration of various types  traversing  Difference between physical and logical size  Dynamic allocation ◦ Parallel arrays ◦ Passing arrays as parameters ◦ 2-D arrays  Game of Life program ◦ Arrays of structures  The tsuPod 1 program ◦ Arrays of Objects  The tsuPod 2 program ◦ Relationship between arrays and pointers

 20 Points ◦ Be able to look at code or algorithm and make an educated guess at the order of magnitude  Look to see if the statement that is executed the most is a function of the size of the data set ◦ Know which orders are faster and slower than the others  Constant time algorithms are denoted as O(1)  O(log 2 n), O(n), O(n 2 ), O(2 n )  There are more

 15 Points ◦ May have to write sequential search, but not the others. ◦ Know the algorithms and the order of magnitude of each  Sequential search  Binary search  Bubble sort  Selection sort

 15 Points ◦ Declaration ◦ Use of the “.” operator ◦ Arrays of structures  tsuPod 2 ◦ Pointers to structures  (*ptr).field  ptr->field ◦ Use of structure as nodes in linked lists  tsuPod 3 program

 50 Points ◦ Fundamentals of class and objects  Declaration  Constructors  Destructors  Instance variables  Instance methods  Class (static) variables  Class (static)methods ◦ Declaration ◦ The “.” operator ◦ Objects as parameters to functions

 Overloading functions ◦ Constructors ◦ Operators  Relational  Other ◦ Using objects as data inside of linked lists ◦ Understand the Exam Grader 2 and the TsuPod projects that used classes.

 25 Points ◦ A pointer is a variable that holds the address of a memory location  Declaration  int *ptr; ◦ Assignment  ptr = &foo; //& is the address function ◦ Dereferencing  *ptr = 54; //same as foo=54; ◦ You can point to any kind of data type ◦ Using pointers to create linked lists

 15 Points ◦ Know the basic commands you needed to complete the last program ◦ Know how to compile and run a C and C++ program in Linux ◦ Know how to create and move around the Linux file system ◦ Simple makefiles

 50 Points ◦ Declaring a linked list ◦ Adding a node to a linked list ◦ Removing a node from a linked list ◦ Traversing a linked list ◦ What is the order of magnitude of each of the above operations? (Big O) ◦ Understand the tsuPod 3 linked list program

 10 Points ◦ Know the fundamental operations and how a stack works  Push  Pop  isFull  isEmpty ◦ A Last in First Out (LIFO) structure ◦ Will not have to code a stack ◦ Understand the Equation Checker program

 5 points ◦ Understand the fundamental operations  enQueue  deQueue  isFull  isEmpty ◦ A First in First Out (FIFO) structure ◦ Will not have to code

 Rewrite all the programs.  Redo labs.  Learn by doing and recognizing patterns.  Don’t stay up late!! Get some sleep and eat a good breakfast.

 Pencils and erasers  We will provide scratch paper  No calculators