Study your flashcards anywhere!

Download the official Cram app for free >

  • Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

How to study your flashcards.

Right/Left arrow keys: Navigate between flashcards.right arrow keyleft arrow key

Up/Down arrow keys: Flip the card between the front and back.down keyup key

H key: Show hint (3rd side).h key

A key: Read text to speech.a key

image

Play button

image

Play button

image

Progress

1/12

Click to flip

12 Cards in this Set

  • Front
  • Back

Three things stored in a stack frame

Return address


Local variables that need to be restored


Parameters that need to be passed to the subroutine

3 advantages of OOP

Easier to amend programs as only the affected module needs editing


Allows multiple programmers to work independently on self-contained modules


Objects can inherit attributes and behaviours, making code reusable throughout the program

Binary tree

Rooted graph in which each node has at most two children

Adjacency matrix for an unweighted graph - how do you represent where there isn't a relationship?

0

Adjacency matrix for a weighted graph - how do you represent where there isn't a relationship?

Infinity sign

Respective symbols for sets of rational and real numbers

Rational: Q


Real: R

When would you use an adjacency list rather than a matrix?

When there are few edges between vertices

Approach to solve an intractable problem (2 marks)

Heuristic


Relax some of the constraints; solve a simpler version of the problem

Base case for a recursive algorithm

The point at which the recursive function will stop calling itself

Difference between composition and aggregation

Composition: if containing object is destroyed so are the objects it contains



Aggregation: if containing object is destroyed the objects it contains aren't

Define set

Unordered collection of values in which each value occurs at most once

ASCII codes for a, A and 0

a: 97


A: 65


0: 48