subroutine - 101 Computing https://www.101computing.net Boost Your Programming Skills! Fri, 30 Aug 2024 21:18:54 +0000 en-US hourly 1 https://www.101computing.net/wp/wp-content/uploads/cropped-android-chrome-512x512-1-32x32.png subroutine - 101 Computing https://www.101computing.net 32 32 Standard Form Conversion Algorithm https://www.101computing.net/standard-form-conversion-algorithm/ Tue, 20 Oct 2020 16:56:07 +0000 https://www.101computing.net/?p=11258 Standard form (a.k.a. standard index form), is a system of writing numbers which is particularly useful when using either very large or very small numbers. It is based on using powers of 10 to express how big or small a

The post Standard Form Conversion Algorithm first appeared on 101 Computing.

]]>
Linear Search Functions https://www.101computing.net/linear-search-functions/ Thu, 27 Feb 2020 09:31:07 +0000 https://www.101computing.net/?p=10447 For this programming challenge we will investigate different functions which will all be based on a linear search algorithm. Let’s consider a teacher who has decided to keep track of rewards issued to their students throughout the term by adding

The post Linear Search Functions first appeared on 101 Computing.

]]>
Leap Year Subroutine https://www.101computing.net/leap-year-subroutine/ Tue, 25 Feb 2020 22:02:17 +0000 https://www.101computing.net/?p=10429 A leap year is a calendar year that contains an additional day (29th of February) added to keep the calendar year synchronised with the astronomical year or seasonal year (which contains roughly 365¼ days or 365.242375 days to be more

The post Leap Year Subroutine first appeared on 101 Computing.

]]>
Graphing Algorithm https://www.101computing.net/graphing-algorithm/ Fri, 14 Jul 2017 12:21:32 +0000 http://www.101computing.net/?p=4878 In this challenge we will write several procedures to graph different mathematical equations on screen using Python Turtle. We will focus on: Linear equations: y = ax + b Quadratic equations: y = ax2 + bx + c Trigonometric functions:

The post Graphing Algorithm first appeared on 101 Computing.

]]>
Connect4 Challenge https://www.101computing.net/connect4-challenge/ Wed, 24 May 2017 13:09:41 +0000 http://www.101computing.net/?p=4660 In this blog post you will use HTML, CSS, and JavaScript to complete this game of connect 4 for two players. (Rules of the game) You will first need to reverse-engineer the code provided. The code so far is used

The post Connect4 Challenge first appeared on 101 Computing.

]]>
Water Polo Challenge https://www.101computing.net/water-polo-challenge/ Mon, 22 May 2017 20:38:00 +0000 http://www.101computing.net/?p=4646 In this challenge you are going to use Python code to score a goal in a game of Water Polo. To do so you will use the code given below. You will pass the ball from one player to another

The post Water Polo Challenge first appeared on 101 Computing.

]]>
Football Formation https://www.101computing.net/football-formation/ Thu, 18 May 2017 21:48:11 +0000 http://www.101computing.net/?p=4604 The purpose of this challenge is to understand how subroutines (functions/procedures) are used in Python to create sections of code that can be called/reused many times within a program. Subroutines mean that a section of code can be identified using

The post Football Formation first appeared on 101 Computing.

]]>
Professor Snape’s Magic Potions https://www.101computing.net/professor-snape-s-magic-potions/ Sat, 18 Mar 2017 18:16:35 +0000 http://www.101computing.net/?p=4218 In this challenge we will use file handling techniques to read through and access the content of different text files. We have saved three recipes for the following three magic potions using one text file per recipe: Invisibility Potion: A

The post Professor Snape’s Magic Potions first appeared on 101 Computing.

]]>
Python Turtle – My House https://www.101computing.net/python-turtle-my-house/ Mon, 28 Nov 2016 15:47:24 +0000 http://www.101computing.net/?p=3580 Using Python Turtle we created a range of functions to draw a house. We use these functions in our main program but can’t seem to get it to work. We believe the code has all the required instructions but these

The post Python Turtle – My House first appeared on 101 Computing.

]]>
Avatar Generator https://www.101computing.net/avatar-generator/ Mon, 27 Jul 2015 12:17:49 +0000 http://www.101computing.net/?p=1929 In this challenge we will use Python Turtle to create avatars. (An avatar is an icon representing a particular person in a computer game, Internet forum, etc.) Try the code below. This code is using a few computing concepts such

The post Avatar Generator first appeared on 101 Computing.

]]>