So, you’ve just finished learning the basics of Python. The question now is, what do you do now? How can you continue to keep developing your coding skills using Python? Do you carry on watching tutorials, or is there something better you can do? The answer is yes there is something better, and that something is working on your own python project. Here are 6 small Python projects you can do as a beginner.

Guess The Number

Write a programme where the computer randomly generates a number between 0 and 20. The user needs to guess what the number is. If the user guesses wrong, tell them their guess is either too high, or too low. This will get you started with the random library if you haven't already used it.

Rock, Paper, Scissors Game

Make a rock-paper-scissors game where it is the player vs the computer. The computer’s answer will be randomly generated, while the program will ask the user for their input. This project will better your understanding of while loops and if statements.

Generating a sine vs cosine curve

For this project, you will have a generate a sine vs cosine curve. You will need to use the numpy library to access the sine and cosine functions. You will also need to use the matplotlib library to draw the curve. To make this more difficult, make the graph go from -360° to 360°, with there being a 180° difference between each point on the x-axis.

Password Generator

Write a programme, which generates a random password for the user. Ask the user how long they want their password to be, and how many letters and numbers they want in their password. Have a mix of upper and lowercase letters, as well as numbers and symbols. The password should be a minimum of 6 characters long.

Hangman

This is probably the hardest one out of these 6 small projects. This will be similar to guessing the number, except we are guessing the word. The user needs to guess letters,

Give the user no more than 6 attempts for guessing wrong letter. This will mean you will have to have a counter. You can download a ‘sowpods’ dictionary file or csv file to use as a way to get a random word to use.

Binary Search Algorithm

Create a random list of numbers between 0 and 100 with a difference of 2 between each number. Ask the user for a number between 0 and 100 to check whether their number is in the list. The programme should work like this. The programme will half the list of numbers and see whether the users number matches the middle element in the list. If they do not match, the programme will check which half the number lies in, and eliminate the other half. The search then continues on the remaining half, again checking whether the middle element in that half is equal to the user’s number. This process keeps on going until the programme finds the users number, or until the size of the subarray is 0, which means the users number isn't in the list.

If you are struggling with any of these, then feel free to message me, or just have a look online as there are plenty of solutions available on platforms such as youtube.