More results...

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
post
page
Python IDE Dashboard

The Explorer’s Challenge: Naming New Species with Code

After months of adventure on the mysterious island of Xylogora, young explorer Mateo has finally returned home. His backpack is stuffed with notes, sketches, and a collection of breathtaking photos of creatures never seen before. From the feathered glimmerfox to the six-legged rippletoad, each animal was stranger and more exotic than the last.

But Mateo has a problem: Every great discovery needs a name, and he has dozens of new species waiting to be named and documented.

Pulling out his laptop, Mateo decides to create a naming algorithm using string-handling techniques. His plan is simple yet ingenious: take the names of existing animals, rearrange their letters, or combine parts of their names to create unique ones. For instance, the “Wolphin” might come from “Wolf” and “Dolphin”.

String Handling Techniques

To create his algorithm, Mateo will need to use the following string handling techniques:


  • LEFT: to extract characters at the beginning of a string,
  • RIGHT: to extract characters at the end of a string,
  • SUBSTR or MID: to extract a set number of characters at a given position in a string,
  • LENGTH: to find out the number of characters in a string,
  • String Concatenation: to join two or more strings together.

LEFTRIGHTSUBSTRString ConcatenationLENGTH
The LEFT() function is used to extract the first 5 characters of a string.

For instance:
LEFT(“WOLF”, 3) would return “WOL”.

The RIGHT() function is used to extract the last 5 characters of a string.

For instance:
RIGHT(“DOLPHIN”, 4) would return “PHIN”.

The SUBSTR() function is used to extract a set number of characters at a given position in a string. Note that in this case the first letter in a string is at position 0.

For instance:
SUBSTR(“PANDA”, 1, 3) would return “AND”.

String concatenation is a technique that uses the + operator to join two or more strings together.

For instance:
“WOL” + “PHIN” would return “WOLPHIN”.

The LENGTH() function is used to retrieve the number of characters in a string.

For instance:
LENGTH(“DOLPHIN”) would return 7.

Naming Unknown Species

Can you work out the name given to the following species?

Python Challenge

Can you help Mateo by writing a Python program that generates exotic animal names using string handling techniques? Your program will need to:

    Takes two (or more) animal names as inputs.
    Randomly combines parts of each name to create a new species name.
    Output the generated name.
    Let the user decide if they like the name or if the computer should have another go.

To do so you will need to complete the code provided below:

unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area

Scheduling Algorithms – Python Challenge

Job Scheduling AlgorithmOne of the main purpose of the Operating System is to control the hardware and more specifically the CPU. The CPU performs all the jobs/processes requested by the different applications. A scheduler is a program of the Operating System that manages the amount of time that is allocated to each job that the CPU needs to process. To do so the scheduler keeps a list of all the jobs that need to be processed. This is called the job queue. The scheduler also uses a scheduling algorithm to determine in which order these jobs will be processed and the amount of processing time to allocate to each job.

The main job scheduling algorithms are:

  • FCFS: First Come First Served
  • Round Robin
  • Shortest Job First
  • Shortest Remaining Time First
  • Multilevel Feedback Queues

The type of algorithm used by an OS depends on the main functions and characteristics of the system and the typical workload and type of jobs the system will need to process. For instance the scheduler inside a networked printer, the scheduler of a personal tablet computer, the scheduler of a smart speaker and the scheduler of a high spec web-server may all use a different approach to managing their job queue!

Use the tabs below to investigate the characteristics, strengths and drawbacks of the main job scheduling algorithms

FCFSRound RobinShortest Job FirstShortest Remaining Time FirstMultilevel Feedback Queues

FCFS (First Come First Served):

Jobs are executed in the order they arrive. The first job to arrive is the first to be executed, and the process continues in this manner.

  • Pros: Simple to implement.
  • Cons: Can lead to long wait times, especially if a long job arrives before shorter ones (known as the “convoy effect”).

Typically a networked printer may use a First Come First Served approach to process each printing job in order they were received/added to the printer queue.

Round Robin (RR):

Each job gets a fixed time slice (quantum). If a job doesn’t finish within its time slice, it’s moved to the back of the queue, and the next job in line is given CPU time.

  • Pros: A fair approach that prevents any job from monopolising the CPU.
  • Cons: Performance can degrade if time slices are too short or too long.

Typically this can be used by multi-user systems such as web servers which have to deal with concurrent requests from many users and want to make sure that each user’s request is processed fairly.

Shortest Job First (SJF):

The job with the shortest burst time (estimated CPU time required) is executed first.

  • Pros: Minimises average waiting time.
  • Cons: Difficult to predict the exact burst time of a job, and can lead to starvation of longer jobs.

Shortest Remaining Time First (SRTF):

A preemptive version of SJF. The job with the shortest remaining time to completion is executed first. If a new job arrives with a shorter remaining time than the current job, the current job is preempted.

  • Pros: Reduces waiting time and responds dynamically to new jobs.
  • Cons: Can lead to frequent context switching and is complex to implement.
  • Cons: Difficult to predict the exact remaining time of a job, and can lead to starvation of longer jobs.

Multilevel Feedback Queues (MLFQ):

Jobs are placed in different priority queues. If a job doesn’t finish quickly enough, it is moved to a lower priority queue with longer time slices. Jobs that use too much CPU time may be demoted, while I/O-bound jobs can be promoted to higher-priority queues.

  • Pros: Adapts well to different types of jobs and improves overall system performance.
  • Cons: Complex to manage and implement.

Python Challenge

A scheduler is part of the Operating system. It would most likely have been programmed using low-level (assembly) language. However for the purpose of this task, we are going to use a Python program to create a high-level demo to show how some of the main scheduling algorithms would process a given job queue.

Python Code

We have started the code for you have implemented the First Come First Served algorithm (FCFS).
Your task is to use a similar approach to implement the following scheduling algorithms:
 First Come First Served algorithm (FCFS)
 Round Robin algorithm
 Shortest Remaining Time First algorithm

unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area

Spot the logic error

Below are 10 different functions. The syntax for these functions is correct, however when testing these functions, you will notice that they do not produce the expected output: each of these functions contain a logic error.

Did you know?

To troubleshoot a piece of code to spot logic errors is called debugging! The reason why a logic error is also called a bug is because one of the first computer programs to not behave as expected was due to an actual moth that was stuck in the electronic components of the computer creating a short circuit. Once the computer scientists spotted this bug, they removed it and the computer program worked again. Since then spotting and removing a logic error in a piece of code is called debugging the code!

Debugging Task

Your task is to copy the code of the following 10 functions in the online IDE provided below to then spot and fix the given code. Make sure to use a range of test data to fully test your functions.

Code #1Code #2Code #3Code #4Code #5Code #6Code #7Code #8Code #9Code #10

Our first function is used to find out if a number is odd or even. For instance check_end_or_odd(5) should output the word “Odd” on the screen.


def check_even_or_odd(number):
    if number % 2 == 1:
        print("Even")
    else:
        print("Odd")
        
check_even_or_odd(5)

Our second function is used to return the largest (max) of 3 numbers.


def findMax(a, b, c):
    if a > b or a > c:
        return a
    elif b > c:
        return b
    else:
        return c
        
print(findMax(7, 3, 9))

This function finds out if a given numebr is a prime number or not.


def isPrime(n):
    for i in range(2, n):
        if n % i == 0:
            return True
    return False

print(isPrime(5))

This function is used to reverse a string so for instance the string 101Computing should become gnitupmoC101.


def reverse_string(text):
    reversed_string = ""
    for char in text:
        reversed_string = reversed_string + char
    return reversed_string

print(reverse_string("101Computing"))

This function counts the number of vowels in a given string. So for instance in the string “Adele” we have 3 vowels.


def countVowels(name):
    vowels = "aeiou"
    count = 0
    for char in name:
        if char in vowels:
            count += 1
    return count

print(countVowels("Adele"))

This function claculate the iterative sum of a number e.gg Iterative Sum of 5 is 1 + 2 + 3 + 4 + 5 = 15


def iterativeSum(n):
    sum = 0
    for i in range(1,n):
        sum = sum + i
    return sum

print("iterativeSum(5) = 5 + 4 + 3 + 2 + 1 = " + str(iterativeSum(5)))

This function calculates a factorial value of any given number. For instance: %5 = 5 x 4 x 3 x 2 x 1 = 120


def factorial(n):
    if n == 0:
       return 1 #because 0! is 1
    else:
       f = 0
       for i in range(1,n+1):
          f = f * i
       return f

print("5! = 5 x 4 x 3 x 2 x 1 = " + str(factorial(5)))

This function counts the number of occurrences of a given value within a given list.


def count_occurrences(list, target):
    count = 0
    for element in list:
        if element == target:
            count = +1
    return count

print(count_occurrences([5, 2, 3, 5, 5, 4, 2], 5))

This function takes a list as a parameter and return another lists by removing all duplicate values from the initial list.


def remove_duplicates(list):
    unique_items = []
    for item in list:
        if item not in unique_items:
            unique_items.append(item)
    return list

print(remove_duplicates([1, 2, 2, 1, 3, 3, 4, 5]))

Our last function is used to display a tic tac toe (aka noughts and crosses) grid on the screen as a 3 by 3 grid.


def printGrid(grid):
   print(" |---+---+---|")
   line = ""   
   for i in range(0,3):
      for j in range(0,3):
         line = line + " | " + tictactoe[i][j]
      print(line + " |")
      print(" |---+---+---|")

tictactoe = [["X","O","X"],["O","X","O"],["X","X","O"]]
printGrid(tictactoe)

Online Python IDE

Use this online Python IDE to test the above functions, spot the logic errors and fix the code!

unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area

Chinese New Year Coding Challenge

Chinese New Year (新年) aka Spring Festival (春节), is one of the most important festivals in Chinese culture. It has been celebrated in China for thousands of years. People celebrate by decorating their interior in red using red couplets of Chinese poetry, lanterns and colourful flowers. The festival is also the opportunity for Chinese people around the world to prepare and enjoy a range of traditional food dishes and to celebrate by watching traditional dragons and lions dances.

Chinese Zodiac Signs

The Chinese New Year is based on the Lunar calendar and typically falls at the end of January or in February depending on the Moon cycle. Every year is associated with an animal corresponding to a Chinese Zodiac sign. There is a 12-year cycle with twelve zodiac signs in the following order:

Animal/Zodiac Sign Years
Dragon … 2000, 2012, 2024 …
Snake … 2001, 2013, 2025 …
Horse … 2002, 2014, 2026 …
Ram (Goat) … 2003, 2015, 2027 …
Monkey … 2004, 2016, 2028 …
Rooster … 2005, 2017, 2029 …
Dog … 2006, 2018, 2030 …
Pig … 2007, 2019, 2031 …
Rat … 2008, 2020, 2032 …
Ox … 2009, 2021, 2033 …
Tiger … 2010, 2022, 2034 …
Rabbit … 2011, 2023, 2035 …

So this year we will celebrate Chinese New Year on January 29th 2025 and the Chinese Zodiac sign / animal for 2025 is the Snake! Maybe a sign that you could dedicate this year to boosting your coding skills using Python 😉

Coding Challenge

For this challenge, you are going to write a Python program that will ask the user to enter the year of their date of birth. Your program will then inform the user of their Chinese Zodiac sign matching their date of birth.

Python Code

Complete the code below to solve this challenge.

Test Plan:

Complete the folowing test plan to check if your code is giving you the correct zodiac signs for he following years (using both past and future years):

Test # Input Values Expected Output Actual Output
#1 Year: 2007 Pig
#2 Year: 2021 Ox
#3 Year: 1998 Tiger
#4 Year: 1912 Rat
#5 Year: 1789 Rooster
#6 Year: 2050 Horse
#7 Year: 2100 Monkey

Extension Task 1:

With the year matching your date of Birth you can also work out what is your Chinese Zodiac element.

To do so you wil need to check the the last digit of your birth year. if this last digit is:

  • 0 or 1: Your element is Metal
  • 2 or 3: Your element is Water
  • 4 or 5: Your element is Wood
  • 6 or 7: Your element is Fire
  • 8 or 9: Your element is Earth

Your task is to tweak your Python code so that when the user enters a date, your program outputs both the Chinese Zodiac sign and the Chinese Zodiac element corresponding to the given year.

Extension Task 2:

Each Zodiac sign has specific attributes which can be used to describe the year to come.

We have stored these attributes using a dictionary:

animals = {"Dragon":"Charismatic, powerful, and ambitious, the Dragon is a symbol of strength and good fortune.",
           "Snake":"Wise, intuitive, and elegant, the Snake is calm and strategic, with a deep understanding of the world.",
           "Horse":"Energetic, free-spirited, and optimistic, the Horse loves adventure and pursues goals with enthusiasm.",
           "Ram":"Creative, gentle, and empathetic, the Goat seeks beauty and tranquillity, often expressing artistic talents.",
           "Monkey":"Intelligent, playful, and clever, the Monkey is resourceful and loves solving problems with wit and charm.",
           "Rooster":"Confident, honest, and hardworking, the Rooster is practical, ambitious, and detail-oriented.",
           "Dog":"Loyal, trustworthy, and protective, the Dog is compassionate and always stands up for what’s right.",
           "Pig":"Generous, kind-hearted, and sincere, the Pig is known for its honesty, hard work, and love of comfort.",
           "Rat":"Intelligent, resourceful, and quick-witted, the Rat excels in finding opportunities and achieving success.",
           "Ox":"Strong, determined, and reliable, the Ox is known for its hardworking nature and steadfast loyalty.",
           "Tiger":"Bold, adventurous, and confident, the Tiger is a natural leader who thrives on challenges.",
           "Rabbit":"Gentle, compassionate, and creative, the Rabbit seeks peace and harmony in its surroundings."
}

Your task is to tweak your code to display the corresponding description of the zodiac sign for the given year.

unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area

Chess Challenge: Checkmate in one move

For this challenge we will use a 8×8 2D array to represent the positions of all the black and white pieces on the chessboard.

We will then use Python Turtle to draw the chessboard using the information stored within the 2D array.

Here is the Python code for our 8×8 2D array:

board = [["bR","bN","bB","bQ","bK","bB","bN","bR"],
         ["bP","bP","bP","bP","bP","bP","bP","bP"],
         ["  ","  ","  ","  ","  ","  ","  ","  "],
         ["  ","  ","  ","  ","  ","  ","  ","  "],
         ["  ","  ","  ","  ","  ","  ","  ","  "],
         ["  ","  ","  ","  ","  ","  ","  ","  "],
         ["wP","wP","wP","wP","wP","wP","wP","wP"],
         ["wR","wN","wB","wQ","wK","wB","wN","wR"]]

In this challenge you will have to make some changes to the board array to move some pieces on the board and solve five different “Checkmate in one move puzzles”. To do you will have to edit the code provided.

Here is an example of how to move on of the white pawn by two places:

board[6][3] = "  " # Remove the white pawn on row 6, column 3
board[4][3] = "wP" # Reposition the white pawn to a new location: row 4, column 3

Checkmate in one move

The code provided below has 5 different puzzles where it is white’s turn to win the game in just one move. Edit the code to implement these moves.

101Computing Dashboard

Are you looking for some inspiration for your next coding challenge? Do you need a selection of programmning projects for your coding club? Or maybe you would like to revise a computer science topic for your GCSE or A Level studies?

Our new dashboard contains a selection of coding challenges, interactive coding puzzles and GCSE and A Level computer science revision topics, all from this computing blog!

101 Computing DashboardOpen in New Window

The Egg Farmer’s Puzzle

An egg farmer is picking up eggs every morning to sell on the local market. Every day, they are picking around 100 to 150 eggs and put these eggs into egg cartons of 12 eggs.

So for instance, if on Monday our farmer picks up 128 eggs, they will use 10 cartons of 12 eggs. (10 x 12 = 120 eggs). With the remaining 8 eggs they will use a carton of 6:

This will mean that the farmer will be left with 2 spare eggs that they will eat for breakfast!

Our farmer would like to use a computer program to help them in the morning to pick up the right number of egg boxes to pack up all the eggs.

Your task is to write a Python program that will:

    Ask the farmer to enter how many eggs they have picked up this morning.
    Work out how many boxes of 12 eggs will be needed today.
    Work out if the farmer will also need a box of 6.
    Finally let the farmer know how many eggs they will have left to cook for breakfast.

Python Codde

Your task is to complete the Python code below:

Test Plan

Is your code complete? Let’s make sure it works as expected by completing the following test plan:

Test # Input Values Expected Output Pass/Fail?
#1 Number of Eggs: 128 You will need 10 cartons of 12.
You will need 1 carton of 6.
You will have 2 eggs for breakfast!
#2 Number of Eggs: 149 You will need 12 cartons of 12.
You will have 5 eggs for breakfast!
#3 Number of Eggs: 105 You will need 8 cartons of 12.
You will need 1 carton of 6.
You will have 3 eggs for breakfast!
unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area

Name the Country: Python Challenge


In this challenge, you will use your Python skills to create a quiz where the player has to guess the name of a country when they can only see the first letter of that country.

When a player gives an incorrect guess, the next letter of the correct answer is revealed.

The quiz should have a scoring system that adds to the player score a number of points corresponding to the number of letters still hidden.

The quiz should repeat itself 10 times, each time with a different country. At the end the computer should reveal the total score of the player.

As an extension task, a leader board should be added to store the player’ name and score in a text file (CSV format).

Structure Diagram

Here is the structure diagram (Decomposition diagram) for this project:

The main tasks for this project are as follows:

    Initialise the game

       Initialise a list of at least 20 countries
       Initialise player score to 0

    Quiz Engine

       Randomly pick a country from the list of countries
       Display the clue (e.g. C _ _ _ _ _ )
       Collect the user guess
       Check if the user is correct and if not repeat the process with a new clue.
       If the user is correct, calculate and display their new score
       Repeat the quiz 10 times with 10 different countries

    Game Over / Leaderboard

       Display a “Game Over” message and the total score
       Ask the player to enter their name
       Store the player’s name and score in a leaderboard file
       Display the leader board (Top 10 scores in descending order)

Displaying the Clue

To help you with this project, we have already created a procedure called displayClue() that takes two parameters: word and x and displays the first x letter of a word following with _ characters for each remaining letters of the given word.

The Python code for our function is as follows:

# A subroutine to display the first x letters of a word
# and replace the remaining letters with _
def displayClue(word,x):
   clue = ""
   for i in range (0, len(word)):
      if i<x:
         clue = clue + word[i]
      else:
         clue = clue + "_"
      clue = clue + " "   
   print("Name the country: " + clue.upper())

Python Code

Your task is to complete the code below to recreate this “Name the Country” Quiz:

unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area

Periodic Table of Elements – JSON Challenge

The periodic table is a chart that organises all known chemical elements based on their atomic number, electron configurations, and recurring chemical properties. It serves as a fundamental tool in chemistry, physics, and other sciences, helping scientists understand the relationships and behaviours of elements.

For this programming challenge, we are going to search through a list of all 118 elements of the Periodic Table to answer specific queries, generate some statistics and create quizzes. All the information needed for this challenge about the elements of the Periodic Table is stored in a JSON file called periodic-table.json.

JavaScript Object Notation (JSON)

JavaScript Object Notation (JSON) is a lightweight, text-based format for storing and exchanging data that is human and machine-readable. It is a standard format that is often used to transfer/retrieve data from a server using an API. It is used in a wide range of web and mobile applications that rely on accessing/exchanging live data.

A JSON file is like a dictionary data structure. It is made up of two primary parts: keys and values. A key/value pair follows a specific syntax:

  • Key: Always a string enclosed in quotation marks
  • Value: Can be a string, number, Boolean expression, array, or object

Complex data structure can be created using JSON by combining {dictionaries} and [arrays].

periodic-table.json

Before attempting this challenge you will need to familiarise yourself with the structure of the provided JSON file: periodic-table.json

Within this file, the main key is “elements”. Its value is an array of all the elements of the Periodic Table. Each element is stored as a dictionary with 4 keys:

  • Symbol: e.g. H
  • Name: e.g. Hydrogen
  • Atomic Number: e.g. 1
  • Atomic Mass: 1.008
  • Phase: Gas

Here is an extract of the periodic-table.json file showing the data for the first three elements: Hydrogen, Helium and Lithium.

{
  "elements": [
	{
	"Symbol": "H",
	"Name": "Hydrogen",
	"Atomic Number": 1,
	"Atomic Mass": 1.008,
	"Phase": "Gas"
	},
	{
	"Symbol": "He",
	"Name": "Helium",
	"Atomic Number": 2,
	"Atomic Mass": 4.0026022,
	"Phase": "Gas"
	},
	{
	"Symbol": "Li",
	"Name": "Lithium",
	"Atomic Number": 3,
	"Atomic Mass": 6.94,
	"Phase": "Solid"
	},

        ...

   ]
}

Python Code

To be able to read and extract data from our JSON file using Python, we will use the json library. Here is an example of how to use Python code to load the JSON data from the periodic-table.json file. We can then perform a basic linear search to retrieve all the elements in the “Solid” form.

import json
 
# load JSON data from file
with open('periodic-table.json','r') as file:
    data = json.load(file)

# Perform a linear search using the JSON data
elements = data["elements"]
for element in elements:
    if element["Phase"]=="Solid":
       print(element["Name"])

You can try and edit this code on our online IDE below:

Your Task:

In the periodic table, the phase of an element refers to its physical state (solid, liquid, or gas) under standard conditions of temperature and pressure (STP), which are typically defined as a temperature of 0°C (273.15 K) and a pressure of 1 atmosphere (atm).

Your task consists of adding extra functions to the above code to perform the following:

     Generate some statistics to calculate and display the percentage of elements in the Periodic Table which are solid, liquid and gas.

     Create a quiz consisting of 10 questions. For each question your program will randomly pick an element from this json file (e.g. Helium) and ask the user to guess its phase (Solid, liquid or gas?).
     Create another quiz where, for each question, your program will randomly pick an element from this json file and display its symbol (e.g. Au) to then ask the user to guess the name of the element (e.g. Gold).

Help…

You can use the following code to randomly pick an element from the periodic table:

import json, random
 
# load JSON data from file
with open('periodic-table.json','r') as file:
    data = json.load(file)

# Perform a linear search using the JSON data
elements = data["elements"]
element = random.choice(elements)

print("Randomly picked element: " + element["Name"])
Tagged with:

Computer Software Card Game

There are a wide range of software that can be used on a computer system and these can be grouped in three main categories:

  • Operating System: The Operating System (OS) is the foundational software that manages a computer’s hardware and software resources, providing a platform for other software to run (e.g., Windows, macOS, Linux).
  • Utility Software: Utility Software includes tools designed to maintain and optimise the performance of the computer, such as antivirus programs, disk defragmentation software, and file management utilities.
  • Application Software: Application Software consists of programs designed for specific user tasks, like word processors, web browsers, graphic editing software and video games, enabling users to perform activities on the computer.

For this challenge we will consider a deck of cards where each card represents a piece of software. The game will consist of randomly selecting three cards from the deck and revealing them to the player:

Based on the cards selected, the player may score points as follows:

Three of a KindSplitPair
Three of a Kind: If all three software are from the same category, the player will score 100 points. This could be when three Operating System cards are revealed, or three utility software or three application software. e.g.

Split: If the first card and the third card are from the same category, the player will score 50 points. Note that the card in the middle will need to be from a different category. e.g.

Pair: If either the first two cards or the last two cards are from the same category, the player will score 30 points. Note that the remaining card will need to be from a different category. e.g.

Python Code


We have started the code by first creating three lists, each of these listing 6 different pieces of software:

OS = ["Windows 10","Linux","MacOS","iOS","Android","MS DoS"]
utilities = ["Anti-Virus Software","Firewall","Encryption Software","File Compression Software","Disk Defragmentation Software","Backup Software"]
application = ["Word Processing Software","Presentation Software","Spreadsheet Software","Web Browser","Graphic Editing Software","Video Editing Software"]

Then we are creating a full deck of 18 cards by combining all three lists into a single list.

software = OS + utilities + application

Using the random library, we can easily pick a random software card from our list of software:

import random
card = random.choice(software)

We can easily check what type of software our card by checking if it belongs to one of the three sub lists:

if card in OS:
   print(card + " is an example of Operating System.")
elif card in utilities:
   print(card + " is an example of Utility Software.")
elif card in application:
   print(card + " is an example of Application Software.")

You can check the following code below. Your task is to complete this code to implement the card game with its scoring system and making sure the player can repeat the process of picking three cards randomly as long as they wish to.

unlock-access

Solution...

The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area