Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture 2 Basic Data Structures and Recursion Review.

Similar presentations


Presentation on theme: "Lecture 2 Basic Data Structures and Recursion Review."— Presentation transcript:

1 Lecture 2 Basic Data Structures and Recursion Review

2 Online Students Tell me what your plan is – in-class exam – proctoring

3 Participation 1 Blue Eyes Problem Due Thursday

4 Abstract Data Type Motivation – Grouping – Abstraction Definition

5 List Operations

6 List: array Characteristics Index calculation (constant)

7 List: array 1D array index calculation (constant)

8 List: array (cont’d) 2D array (RMO)

9 List: array (cont’d) 2D array (CMO)

10 List: array (cont’d) 3D array

11 List: array

12 Resizing: what’s the cost? Increase capacity by 1 Increase capacity by 100%

13 List: linked list Characteristics

14

15 List: doubly-linked list Characteristics

16 List: doubly-linked list

17 List: Circular linked list Characteristics

18 List: Circular linked list

19 List: Multi-List Characteristics

20 List: Multi-List

21 Stacks Operations

22 Stacks: arrays Push()

23 Stacks: arrays Pop()

24 Stacks: arrays

25 Stacks: linked lists Push()

26 Stacks: linked lists Pop()

27 Queues Characteristics

28 Queues: linked list enqueue

29 Queues: linked list dequeue

30 Queues: array enqueue

31 Queue: array dequeue

32 Dictionary Characteristics

33 Dictionary: implementations Hash Table B+ Trees

34 Other data structures Trees Graphs

35 Recursion Review Definition

36 Recursion Review Example: factorial

37 Recursion Review

38 Any recursive function can be rewritten as a loop.

39 Recursion Review Recursion vs loops

40 Recursion Review Reverse Linked List (iterative)

41 Recursion Review Reverse Linked List (recursive)

42 Recursion Review Reverse Linked List (recursive)

43 Recursion Review

44 Recursion Review: Towers of Hanoi image from wikipedia

45 Recursion Review: Towers of Hanoi image from mathworld.wolfram.com

46 Recursion Review Solving Towers of Hanoi Recursively

47 Lecture 2 Basic Data Structures and Recursion Review

48 Online Students Tell me what your plan is – in-class exam – proctoring

49 Participation 1 Blue Eyes Problem Due Thursday

50 Abstract Data Type Motivation – Grouping – Abstraction Definition

51 List Operations

52 List: array Characteristics Index calculation (constant)

53 List: array 1D array index calculation (constant)

54 List: array (cont’d) 2D array (RMO)

55 List: array (cont’d) 2D array (CMO)

56 List: array (cont’d) 3D array

57 List: array

58 Resizing: what’s the cost? Increase capacity by 1 Increase capacity by 100%

59 List: linked list Characteristics

60

61 List: doubly-linked list Characteristics

62 List: doubly-linked list

63 List: Circular linked list Characteristics

64 List: Circular linked list

65 List: Multi-List Characteristics

66 List: Multi-List

67 Stacks Operations

68 Stacks: arrays Push()

69 Stacks: arrays Pop()

70 Stacks: arrays

71 Stacks: linked lists Push()

72 Stacks: linked lists Pop()

73 Queues Characteristics

74 Queues: linked list enqueue

75 Queues: linked list dequeue

76 Queues: array enqueue

77 Queue: array dequeue

78 Dictionary Characteristics

79 Dictionary: implementations Hash Table B+ Trees

80 Other data structures Trees Graphs

81 Recursion Review Definition

82 Recursion Review Example: factorial

83 Recursion Review

84 Any recursive function can be rewritten as a loop.

85 Recursion Review Recursion vs loops

86 Recursion Review Reverse Linked List (iterative)

87 Recursion Review Reverse Linked List (recursive)

88 Recursion Review Reverse Linked List (recursive)

89 Recursion Review

90 Recursion Review: Towers of Hanoi image from wikipedia

91 Recursion Review: Towers of Hanoi image from mathworld.wolfram.com

92 Recursion Review Solving Towers of Hanoi Recursively


Download ppt "Lecture 2 Basic Data Structures and Recursion Review."

Similar presentations


Ads by Google