diff --git a/labs/09-trees-exercises.ipynb b/labs/09-trees-exercises.ipynb
new file mode 100644
index 0000000000000000000000000000000000000000..1819ae0fb3352d7450d8c216dedb321896986e96
--- /dev/null
+++ b/labs/09-trees-exercises.ipynb
@@ -0,0 +1,711 @@
+{
+ "cells": [
+  {
+   "cell_type": "markdown",
+   "id": "30b07ee7",
+   "metadata": {},
+   "source": [
+    "NAME:"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "4ef6c0ef-cf70-45dd-af93-5a910c414ea1",
+   "metadata": {},
+   "source": [
+    "# UE5 Fundamentals of Algorithms\n",
+    "# Lab 9: Trees"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "34c7a5e4-9f95-48fc-9729-5b0b7c76ea64",
+   "metadata": {},
+   "source": [
+    "---"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "c62d36f3-db61-40b0-add2-d2da652708fd",
+   "metadata": {},
+   "source": [
+    "## Exercise 1: Compare two trees data structures\n",
+    "\n",
+    "You are given a tree data structure as a dictionnary, e.g:"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "58d3c26d-d101-45d3-9283-44427258854b",
+   "metadata": {
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "tree_dict = {\n",
+    "    'a': ['b', 'c'],\n",
+    "    'b': ['d', 'e'],\n",
+    "    'c': ['f'],\n",
+    "    'd': [],\n",
+    "    'e': [],\n",
+    "    'f': []\n",
+    "}"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "134fc918-8d81-43f8-b847-be70b3047d25",
+   "metadata": {},
+   "source": [
+    "And another one as an Object:"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "deea1d47-404d-43df-adee-5c49427598c8",
+   "metadata": {
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "class Node:\n",
+    "    def __init__(self, value = None, children = []):\n",
+    "        self.value = value\n",
+    "        self.children = children"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "c77a0f57-7f47-4eb7-b673-1972398106c7",
+   "metadata": {},
+   "source": [
+    "Implement the following:\n",
+    "\n",
+    "1. Use the above data structure to store the first 6 letters of the alphabet in alphabetical order (if the tree is traversed using bfs)\n",
+    "2. A bfs function to compare the trees (i.e. the bfs function returns the same nodes in the same order)"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "59f3995a-3e79-401b-8813-7543037841b2",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "1515caddae1f85a370f021fa206c3406",
+     "grade": false,
+     "grade_id": "cell-e3c919e88440ce72",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "0ee4bcec-c701-4558-b35d-4ce49a953f47",
+   "metadata": {},
+   "source": [
+    "## Exercise 2: Return the list of links from a tree\n",
+    "\n",
+    "Given the two data structure from the previous exercise (i.e. dict and object), return the list of edges of those two trees in the same order and compare them. Return -1 if the trees have a cycle."
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "f521a89e-c319-4180-94e1-adb1cd7832ad",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "013abb9a723b2dff7d5b15f884a5e289",
+     "grade": false,
+     "grade_id": "cell-53bb2a8f08b5b459",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_edges_node(root):\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "78392fbd-7887-4e91-b006-8785e1d135d4",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "5c8a5a14c81e5ee29da9a49a4fa6d2d9",
+     "grade": false,
+     "grade_id": "cell-d46da0388a47efdc",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_edges_dict(tree_dict, start_node):\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "f711a8a8-420c-4eff-9227-90c9b933bdba",
+   "metadata": {
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "assert get_edges_dict(tree_dict, 'a') == get_edges_node(root)"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "8b7b3ed0-771b-49b4-b1ca-4d7ffde0cae5",
+   "metadata": {},
+   "source": [
+    "## Exercise 3: Calculate the total weight of a weighted tree\n",
+    "\n",
+    "Update the two previous data structure to store a weight value. The weight is stored in links and is any numerical value. For the dictionnary, adapt the data structured using named values as below. Provide examples of weighted trees similar as the previous questions (you assign random weights, if no weight then assign `0`)."
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "0780439e-6d76-4576-9669-0c94c8a7b476",
+   "metadata": {
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "tree_dict_weight = {\n",
+    "    \"a\": {\"neighbors\": [\"b\", \"c\"]},\n",
+    "    \"b\": {\"neighbors\": [\"d\", \"e\"]},\n",
+    "    \"c\": {\"neighbors\": [\"f\"]},\n",
+    "    \"d\": {\"neighbors\": []},\n",
+    "    \"e\": {\"neighbors\": []},\n",
+    "    \"f\": {\"neighbors\": []}\n",
+    "}"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "8209cb32-7d73-44a4-af00-85d73a80f5ca",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "687b9e84142eb165ae827c3f042053e1",
+     "grade": false,
+     "grade_id": "cell-0ebc501702fdb5a4",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "6436c778-b2b4-44a1-8998-892cdab9a9e9",
+   "metadata": {},
+   "source": [
+    "Write some tests"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "adf4724c-ce18-4f66-8fa2-ac5199a4fd69",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "362a8ecc22068590e5afc240e80ffcc8",
+     "grade": false,
+     "grade_id": "cell-c9a6287bd6ca9388",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "7bc1c52d-1701-47d8-88ee-bc02e0188261",
+   "metadata": {},
+   "source": [
+    "## Exercise 4: Check if the a is an n-ary tree\n",
+    "\n",
+    "A $n$-ary tree with $n=2$ is a binary tree. Write solution that are recursive, and for the dict and Node data structures."
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "776f8fdd-dd91-4cfc-a239-0a00bceb9e40",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "cc7704cf4a0b6cb8f5a2c70de70c1b37",
+     "grade": false,
+     "grade_id": "cell-12661c11043349ab",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def is_nary_tree_dict(tree, node, n = 2, visited=None):\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "01df4470-fab0-4cc2-a58b-0c22d4ed5754",
+   "metadata": {},
+   "source": [
+    "Write some tests"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "f2ef2bfb-35af-45ed-b526-6a69f8890282",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "ec396993c848d4d93ba0a4b519f3e542",
+     "grade": false,
+     "grade_id": "cell-1eaf29113206c31d",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def is_nary_tree_node(root, n = 2, visited=None):\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "cd6d9842-f110-46e3-9869-24cfc5f301e7",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "4a9fcb5aa0695ca74b9b36fc5dc1432e",
+     "grade": false,
+     "grade_id": "cell-b78a8de1ea2ab199",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "9d03a5bf-205f-4a5e-9446-d57b9800e0aa",
+   "metadata": {},
+   "source": [
+    "## Exercise BONUS: Update the Node class with the following methods\n",
+    "\n",
+    "You may progressively update the class property methods with `Node.your_method`\n"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "3085f09f-5bc2-4bfe-b082-46b1fc579a84",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "3023013b8cc07fb4969aa475cd8eeaaf",
+     "grade": false,
+     "grade_id": "cell-618403002a124a8b",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_children(self): # return all the children of the current node\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "8750c154-28e6-4165-a682-5d3995ead561",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "f9778098a866ea93ff7be2bce79cca06",
+     "grade": false,
+     "grade_id": "cell-7658fd50d1a6640f",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def is_root(self): # check of the current node is a root node\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "bd3e2185-8c19-48ed-89e3-ae6499e2acf2",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "5c6a98be1d3d1d4a03435bd5bddf934e",
+     "grade": false,
+     "grade_id": "cell-713bb31725abd453",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_nodes(self): # get all the nodes of the tree (or sub-tree)\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "5a713b70-bcf9-4850-a874-750ca25c2895",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "52ba24b762118a841baa9f8ee9276e8a",
+     "grade": false,
+     "grade_id": "cell-a335b930ac93a5e5",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_edges(self): # get all the edges of the tree (or sub-tree)\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "aa0619f4-758e-4b67-a8f9-edfdc13b109d",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "fe71733d4964e2a7d7360e68a05877df",
+     "grade": false,
+     "grade_id": "cell-601da6374219c6de",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_parent(self): # return the parent of a given node\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "a4f871d3-4fae-4819-8fe3-675f2f8ea310",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "f0e40867a13605bd7edfdeed03021bca",
+     "grade": false,
+     "grade_id": "cell-744461e5cdd2c364",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def is_parent(self, node): # check if the parent of a given node\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "55af73bd-7793-402c-b1aa-cf976420c904",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "018bfec08e7993beed563ff175b5f589",
+     "grade": false,
+     "grade_id": "cell-3d9c70e0373783db",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_height(self, parent): # return the height of a node\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "be881a18-5e7d-44ee-a59d-a3211bc4d9c4",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "f9b9d60233035110e651367c1d3a45d0",
+     "grade": false,
+     "grade_id": "cell-8df451890eb0851b",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_siblings(self): # return all the nodes with the same height\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "6bc87519-f219-4f42-81d9-bef7c92483ec",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "287036dd946026719b95b37d182d5a89",
+     "grade": false,
+     "grade_id": "cell-e0f74e8bb091ab18",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_leaves(self): # get all the leaves of the sub-tree\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "1ff5ce8d-4539-4c67-a249-8ce1638fbc37",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "e833d3c150909538bd7291e2e2f8c622",
+     "grade": false,
+     "grade_id": "cell-05662988e3373818",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def is_leaf(self): # check if a node is a leaf\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "f4505be1-0f79-40f8-adfd-9bbb184d3671",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "0106fa95f192c9a1cb0daf5f07407668",
+     "grade": false,
+     "grade_id": "cell-8fb25a1f664ec637",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "def get_edges(self): # get edges of a sub-tree\n",
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "3fba7abb-00ea-49ff-945e-91bda370d1e6",
+   "metadata": {},
+   "source": [
+    "Write tests."
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "acb7b4b0-af3b-42c0-bacb-f97d4fd2b530",
+   "metadata": {
+    "deletable": false,
+    "nbgrader": {
+     "cell_type": "code",
+     "checksum": "f223f7dca9a220da5b3eab0613b673e6",
+     "grade": false,
+     "grade_id": "cell-308d6a53c2dc721a",
+     "locked": false,
+     "schema_version": 3,
+     "solution": true,
+     "task": false
+    },
+    "tags": []
+   },
+   "outputs": [],
+   "source": [
+    "# YOUR CODE HERE\n",
+    "raise NotImplementedError()"
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "81d762d6-42ca-444d-a633-503880364f11",
+   "metadata": {},
+   "outputs": [],
+   "source": []
+  }
+ ],
+ "metadata": {
+  "kernelspec": {
+   "display_name": "Python 3 (ipykernel)",
+   "language": "python",
+   "name": "python3"
+  },
+  "language_info": {
+   "codemirror_mode": {
+    "name": "ipython",
+    "version": 3
+   },
+   "file_extension": ".py",
+   "mimetype": "text/x-python",
+   "name": "python",
+   "nbconvert_exporter": "python",
+   "pygments_lexer": "ipython3",
+   "version": "3.10.9"
+  }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 5
+}