<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://www.waterwaysinwhittlesea.org/index.php?action=history&amp;feed=atom&amp;title=Worksheet_5_-_Python_Introduction</id>
	<title>Worksheet 5 - Python Introduction - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://www.waterwaysinwhittlesea.org/index.php?action=history&amp;feed=atom&amp;title=Worksheet_5_-_Python_Introduction"/>
	<link rel="alternate" type="text/html" href="http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;action=history"/>
	<updated>2026-11-13T15:19:35Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.4</generator>
	<entry>
		<id>http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;diff=10310&amp;oldid=prev</id>
		<title>EdmondLascaris at 09:50, 27 October 2024</title>
		<link rel="alternate" type="text/html" href="http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;diff=10310&amp;oldid=prev"/>
		<updated>2024-10-27T09:50:11Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;amp;diff=10310&amp;amp;oldid=10309&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>EdmondLascaris</name></author>
	</entry>
	<entry>
		<id>http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;diff=10309&amp;oldid=prev</id>
		<title>EdmondLascaris at 09:37, 27 October 2024</title>
		<link rel="alternate" type="text/html" href="http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;diff=10309&amp;oldid=prev"/>
		<updated>2024-10-27T09:37:26Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 09:37, 27 October 2024&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l13&quot;&gt;Line 13:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 13:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=Input from the User=&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;=Input from the User=&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;python&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Copy code&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;syntaxhighlight lang=&quot;&lt;/ins&gt;python&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&quot;&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;# Basic input&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;# Basic input&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;name = input(&amp;quot;Enter your name: &amp;quot;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;name = input(&amp;quot;Enter your name: &amp;quot;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;print(&amp;quot;Hello,&amp;quot;, name, &amp;quot;!&amp;quot;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;print(&amp;quot;Hello,&amp;quot;, name, &amp;quot;!&amp;quot;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Task: Ask the user for their age and print it.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Task: Ask the user for their age and print it.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l32&quot;&gt;Line 32:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 34:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;print(7 * 6)   # Multiplication&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;print(7 * 6)   # Multiplication&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;print(8 / 2)   # Division&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;print(8 / 2)   # Division&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Task: Create a program that calculates the area of a rectangle (length * width).&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Task: Create a program that calculates the area of a rectangle (length * width).&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>EdmondLascaris</name></author>
	</entry>
	<entry>
		<id>http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;diff=10308&amp;oldid=prev</id>
		<title>EdmondLascaris: Created page with &quot;=Printing Output=  &lt;syntaxhighlight lang=&quot;python&quot;&gt; # Basic printing print(&quot;Hello, World!&quot;) &lt;/syntaxhighlight&gt; Task: Modify the code to print a personal greeting like &quot;Hello, [Your Name]!&quot;  Additional Challenge: Ask the user for their name and greet them personally.  Bonus Challenge: Modify the program to greet two different names in separate lines.   =Input from the User= python Copy code # Basic input name = input(&quot;Enter your name: &quot;) print(&quot;Hello,&quot;, name, &quot;!&quot;) Task: As...&quot;</title>
		<link rel="alternate" type="text/html" href="http://www.waterwaysinwhittlesea.org/index.php?title=Worksheet_5_-_Python_Introduction&amp;diff=10308&amp;oldid=prev"/>
		<updated>2024-10-27T08:04:40Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;=Printing Output=  &amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt; # Basic printing print(&amp;quot;Hello, World!&amp;quot;) &amp;lt;/syntaxhighlight&amp;gt; Task: Modify the code to print a personal greeting like &amp;quot;Hello, [Your Name]!&amp;quot;  Additional Challenge: Ask the user for their name and greet them personally.  Bonus Challenge: Modify the program to greet two different names in separate lines.   =Input from the User= python Copy code # Basic input name = input(&amp;quot;Enter your name: &amp;quot;) print(&amp;quot;Hello,&amp;quot;, name, &amp;quot;!&amp;quot;) Task: As...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;=Printing Output=&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
# Basic printing&lt;br /&gt;
print(&amp;quot;Hello, World!&amp;quot;)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Task: Modify the code to print a personal greeting like &amp;quot;Hello, [Your Name]!&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Ask the user for their name and greet them personally.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Modify the program to greet two different names in separate lines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Input from the User=&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Basic input&lt;br /&gt;
name = input(&amp;quot;Enter your name: &amp;quot;)&lt;br /&gt;
print(&amp;quot;Hello,&amp;quot;, name, &amp;quot;!&amp;quot;)&lt;br /&gt;
Task: Ask the user for their age and print it.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Write a program that asks for the user’s birth year, calculates their age, and prints it.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Modify the program to ask for the user’s favorite food and print, &amp;quot;Hello [name], who is [age] years old and loves [food]!&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=Basic Math Operations=&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Basic operations&lt;br /&gt;
print(5 + 3)   # Addition&lt;br /&gt;
print(10 - 4)  # Subtraction&lt;br /&gt;
print(7 * 6)   # Multiplication&lt;br /&gt;
print(8 / 2)   # Division&lt;br /&gt;
Task: Create a program that calculates the area of a rectangle (length * width).&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Ask the user to input the rectangle’s length and width.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Create a calculator that allows the user to choose the operation (addition, subtraction, etc.) they want to perform on two numbers.&lt;br /&gt;
&lt;br /&gt;
3. Variables&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Storing and printing variables&lt;br /&gt;
name = &amp;quot;Alice&amp;quot;&lt;br /&gt;
favorite_number = 7&lt;br /&gt;
print(&amp;quot;My name is&amp;quot;, name, &amp;quot;and my favorite number is&amp;quot;, favorite_number)&lt;br /&gt;
Task: Assign a new value to favorite_number and print it out.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Prompt the user for their favorite color, store it in a variable, and print a statement like &amp;quot;My favorite color is [color].&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Write a small program that asks for the user’s name and age, then prints a statement with both.&lt;br /&gt;
&lt;br /&gt;
4. Data Types&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Assigning different data types&lt;br /&gt;
my_string = &amp;quot;Hello&amp;quot;&lt;br /&gt;
my_integer = 25&lt;br /&gt;
my_float = 3.14&lt;br /&gt;
&lt;br /&gt;
print(&amp;quot;String:&amp;quot;, my_string, type(my_string))&lt;br /&gt;
print(&amp;quot;Integer:&amp;quot;, my_integer, type(my_integer))&lt;br /&gt;
print(&amp;quot;Float:&amp;quot;, my_float, type(my_float))&lt;br /&gt;
Task: Create a new variable of type boolean (True/False) and print its type.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Write a program that uses an integer and a float and prints their sum.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Ask the user to input a number and print its type.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6. Conditional Statements&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Basic conditional check&lt;br /&gt;
number = int(input(&amp;quot;Enter a number: &amp;quot;))&lt;br /&gt;
if number &amp;gt; 0:&lt;br /&gt;
    print(&amp;quot;Positive number&amp;quot;)&lt;br /&gt;
elif number &amp;lt; 0:&lt;br /&gt;
    print(&amp;quot;Negative number&amp;quot;)&lt;br /&gt;
else:&lt;br /&gt;
    print(&amp;quot;Zero&amp;quot;)&lt;br /&gt;
Task: Modify the program to check if the number is even or odd.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Write a program to check if the input number is divisible by 5.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Add a check to see if the number is a multiple of both 2 and 3.&lt;br /&gt;
&lt;br /&gt;
7. Loops&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Printing numbers from 1 to 10&lt;br /&gt;
for i in range(1, 11):&lt;br /&gt;
    print(i)&lt;br /&gt;
Task: Print only even numbers from 1 to 10.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Write a loop to print numbers from 1 to 10 in reverse order.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Use a loop to calculate the sum of numbers from 1 to 20.&lt;br /&gt;
&lt;br /&gt;
8. Lists&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Basic list and printing items&lt;br /&gt;
favorite_foods = [&amp;quot;Pizza&amp;quot;, &amp;quot;Burgers&amp;quot;, &amp;quot;Ice Cream&amp;quot;]&lt;br /&gt;
for food in favorite_foods:&lt;br /&gt;
    print(food)&lt;br /&gt;
Task: Add a new food item to the list and print all items.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Write a program that asks the user for their top 3 favorite movies and stores them in a list.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Create a list of numbers, find the maximum, minimum, and average of the list, and print each.&lt;br /&gt;
&lt;br /&gt;
9. Functions&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Basic function&lt;br /&gt;
def greet(name):&lt;br /&gt;
    print(&amp;quot;Hello,&amp;quot;, name, &amp;quot;!&amp;quot;)&lt;br /&gt;
greet(&amp;quot;Alice&amp;quot;)&lt;br /&gt;
Task: Write a function that calculates the square of a number and returns the result.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Write a function to calculate the area of a triangle, given base and height.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Write a function that takes two numbers and returns their sum, difference, product, and quotient.&lt;br /&gt;
&lt;br /&gt;
10. String Manipulation&lt;br /&gt;
python&lt;br /&gt;
Copy code&lt;br /&gt;
# Convert string to uppercase&lt;br /&gt;
sentence = input(&amp;quot;Enter a sentence: &amp;quot;)&lt;br /&gt;
print(&amp;quot;Uppercase:&amp;quot;, sentence.upper())&lt;br /&gt;
Task: Print the sentence in lowercase.&lt;br /&gt;
&lt;br /&gt;
Additional Challenge: Replace all spaces in the sentence with underscores.&lt;br /&gt;
&lt;br /&gt;
Bonus Challenge: Write a program that asks for a word and checks if it’s a palindrome (same forwards and backwards).&lt;/div&gt;</summary>
		<author><name>EdmondLascaris</name></author>
	</entry>
</feed>