"Try out different cell types, including code and markdown cells."
]
},
{
"cell_type": "markdown",
"id": "4cd048de",
"metadata": {},
"source": [
"### 1: Markdown cells"
]
},
{
"cell_type": "markdown",
"id": "f9f4a25b",
"metadata": {},
"source": [
"#### 1.1 Headers in Markdown\n",
"\n",
"Create 4 header levels using Markdown. Each header should be labeled as \"Level 1\", \"Level 2\", \"Level 3\", and \"Level 4\", corresponding to the Markdown syntax for headers.<br>"
]
},
{
"cell_type": "markdown",
"id": "4e959eae",
"metadata": {},
"source": [
"# Level 1\n",
"\n",
"## Level 2\n",
"\n",
"### Level 3\n",
"\n",
"#### Level 4"
]
},
{
"cell_type": "markdown",
"id": "9778cbbe",
"metadata": {},
"source": [
"#### 1.2 Text formatting in Markdown\n",
"Write the following words with the desired formatting using a line break between each word <br>\n",
"A word printed **in bold**: “Word1” <br>\n",
"One word printed in *italics*: “Word2” <br>\n",
"One ~~strikethrough~~ word: “Word3” <br>\n",
"One ___italic and bold word___: “Word4” <br>\n",
"\n"
]
},
{
"cell_type": "markdown",
"id": "b0a6b08a",
"metadata": {},
"source": [
"**Word 1**\n",
"\n",
"*Word 2*\n",
"\n",
"~~Word 3~~\n",
"\n",
"***Word 4***"
]
},
{
"cell_type": "markdown",
"id": "189de41f",
"metadata": {},
"source": [
"#### 1.3 Tables in Markdown\n",
"\n",
"Create a table with three columns and three rows that contains the profiles of three individuals, including their name, age, and profession. <br>\n",
"Use the extension **\"Nice Tables\"** for this\n",
"\n",
"\n",
"1. To download the extension, open the Extensions Menu on the left side of your Markdown editor.\n",
"2. Search for \"Nice Tables\" and install it.\n",
"3. Once installed, use it to create the table structure and fill it with the appropriate data.\n",
"4. Open the Command Menu with CTRL + SHIFT + P.\n",
"5. Search for \"Text Tables: Create Table\".\n",
"6. Enter the desired table size. You can navigate between cells using the Tab key. The size of the cells should adjust automatically.\n",
"\n",
"\n",
"\n",
"\n"
]
},
{
"cell_type": "markdown",
"id": "80a329a0",
"metadata": {},
"source": [
"| Name | Age | Profession | \n",
"|-----|-----|-----| \n",
"| Andri | 30 | Student | \n",
"| Jonas | 24 | Student | \n",
"| Andrin | 24 | Student | "
]
},
{
"cell_type": "markdown",
"id": "e3d789bd",
"metadata": {},
"source": [
"#### 1.4 Mathematical formulas in Markdown\n",
"Insert the formula for calculating the volume of a sphere from a radius <br>\n",
"> here a Cheat sheet that can help: https://www.upyesp.org/posts/makrdown-vscode-math-notation/ \n",
"\n",
"Example midnight formula:\n",
"x = $\\frac{-b \\pm \\sqrt{b^2 - 4ac}}{2a}$\n"
]
},
{
"cell_type": "markdown",
"id": "4845547f",
"metadata": {},
"source": [
"\n",
"V = $\\frac{4}{3} \\times r^3 \\times \\pi$\n",
"\n",
"x = $\\frac{-b \\pm \\sqrt{b^2-4ac}}{2a}$\n"
]
},
{
"cell_type": "markdown",
"id": "303a067d",
"metadata": {},
"source": [
"#### 1.5 Links and Images\n",
"##### 1.5.1 Web Images\n",
"Add any image from the web in Markdown and add a hyperlink with the URL matching the image<br>\n"
"[Hyperlink to OST Logo](https://play-lh.googleusercontent.com/0kESu2OP8SRdQ2IvnlBXY1SKtIKy2-OpxXpc1Yf-KHCDE3B0eATDdFJ-PzgGkI4v8g)"
]
},
{
"cell_type": "markdown",
"id": "be12e31e",
"metadata": {},
"source": [
"##### 1.5.2 local Images\n",
"Add an image to the project by first creating a new folder named Pictures inside the week_1 folder. Place the image file in this folder and update the Markdown file with a relative link to the image, ensuring the link works regardless of where the project is saved or moved.\n",
"\n",
"> To make sure the link works universally, use a relative path like (./week_1/Pictures/image_name.jpg)\" instead of an absolute path."
"Create an ordered list as shown in the example below\n",
"\n",
"1. First item\n",
"2. Second item\n",
"3. Third item\n",
" 1. Indented item\n",
" 2. Indented item\n",
"4. Fourth item \n",
"<br> <br>\n",
"The list should consist of two main items fruits and vegetables, with sub-items of fruits being bananas and apples and sub-items of vegetables being carrots and potatoes"
]
},
{
"cell_type": "markdown",
"id": "5795b9c2",
"metadata": {},
"source": [
"1. First item\n",
"\n",
"1. Second item\n",
"\n",
"1. Third item \n",
" 1. Indented item\n",
" 1. Indented item\n",
"1. Fourth item"
]
},
{
"cell_type": "markdown",
"id": "8e9c74ff",
"metadata": {},
"source": [
"1. **fruits**\n",
" 1. bananas\n",
" 1. apples\n",
" \n",
"1. **vegetables**\n",
" 1. carrots\n",
" 1. potatoes"
]
},
{
"cell_type": "markdown",
"id": "68f111de",
"metadata": {},
"source": [
"##### 1.6.1 Bulletpoint lists\n",
"Create an unordered list with bullet points with Point 1 Point 2"
]
},
{
"cell_type": "markdown",
"id": "91fa94cf",
"metadata": {},
"source": [
"* ***Point 1***\n",
"* **Point 2**\n",
"* *Point 3*\n",
"* Point 4"
]
},
{
"cell_type": "markdown",
"id": "91106711",
"metadata": {},
"source": []
},
{
"cell_type": "markdown",
"id": "81e4c706",
"metadata": {},
"source": [
"1.7 Quotes\n",
"Make the sentence below a quotation <br>\n",
"Programming is the art of telling another human being what one wants the computer to do."
]
},
{
"cell_type": "markdown",
"id": "177f1a55",
"metadata": {},
"source": [
"> \"Programming is the art of telling other human being what one wants the computer to do.\""
]
},
{
"cell_type": "markdown",
"id": "97ae5c25",
"metadata": {},
"source": [
"#### 2: Code Cells\n"
]
},
{
"cell_type": "markdown",
"id": "432de469",
"metadata": {},
"source": [
"#### 2.1 Hello world!\n",
"Next insert a code cell which displays hello world!\n"
]
},
{
<<<<<<< HEAD
"cell_type": "code",
"execution_count": 1,
"id": "24dc251f",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Hello World!\n"
]
}
],
"source": [
"msg = \"Hello World!\"\n",
"print(msg)"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "11ffe117",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Hello again!\n"
]
}
],
"source": [
"print(\"Hello again!\")"
]
},
{
=======
>>>>>>> ee7241d406611ae6f4b624b57678d19a460cc4be
"cell_type": "markdown",
"id": "bc1be52c",
"metadata": {},
"source": [
"#### 2.2: First step in Python"
]
},
{
"cell_type": "markdown",
"id": "d4cc568a",
"metadata": {},
"source": [
"Create a Python program that performs the following arithmetic operations using two variables ``a`` and ``b``\n",