levo

Advanced Data Structures and Logic

Binary trees using pointers and arrays

  • 3 things to know
  • A2 Unit 3

Overview

Binary tree, root of a tree and leaf node.

What you need to know

Answer each one before you reveal it.

Your recallNot started
Key term

What is a binary tree?

Key term

Define the root of a tree.

Key term

What is a leaf node?

Questions from this subtopic

Each one with the model answer underneath.

  1. 1

    What is a binary tree?

    Model answer

    A binary tree is a structure of nodes in which every node has at most two children, referred to as its left child and its right child.

  2. 2

    Define the root of a tree.

    Model answer

    The root is the single node that has no parent, and it is the node from which every other node is reached.

  3. 3

    What is a leaf node?

    Model answer

    A leaf node is a node with no children.

  4. 4

    What is a binary search tree?

    Model answer

    A binary search tree is a binary tree ordered so that every value in a node's left subtree is smaller than that node and every value in its right subtree is larger.

  5. 5

    What does a node of a binary tree hold when the tree is built with pointers?

    Model answer

    It holds the data item, a pointer to the left child and a pointer to the right child, with a null pointer wherever a child is absent.

  6. 6

    How is a binary tree represented using arrays?

    Model answer

    Three parallel arrays hold the data, the subscript of the left child and the subscript of the right child, with a reserved value such as −1 standing for a null pointer.

Other ways to work this

The same content, four other ways.

What is inside Levo

Six ways to work the same material.

1Closed book
2Open book
3Closed book

The 3-step method, run for you

Answer cold, learn it, then prove it stuck. Levo tracks the jump between your first attempt and your last.

Hardware: Architecture, Memory and Storage
Networks and Data Transmission
Logic Gates and Boolean Algebra
Data Representation and Data Types

Cram a whole paper in one sitting

Sort every topic into what you know and what you do not, then drill only the weak ones.

Fetch, , execute.
decodecompilestore

Blank Blitz makes facts automatic

Rapid timed gap-fills on the terms and numbers you need to recall without thinking.

AEncryption is reversible.
BThe stored form could be decrypted.
CA hash cannot be reversed.

Build It gets the exam shape right

Assemble a full-mark answer from its marking points, in the order an examiner wants them.

A bit is a single binary digit.
TrueFalse

Test It catches misconceptions

Spot the fault in a statement. The traps are the mistakes students actually make.

721941163128510

Brain Breaks between sessions

Short focus games to reset attention, so the next set lands better than the last.

Every question in Advanced Data Structures and Logic, on a schedule.

Attempt a question from memory, write the correct version, then attempt it again. Levo records the jump between your first attempt and your last, and brings each question back on the day you are due to forget it.

Or £46 a year, about £3.83 a month. Cancel anytime.