GCSE COMPUTER SCIENCE Practical Programming using Python

Slides:



Advertisements
Similar presentations
ENGLISH AS A SECOND LANGUAGE PRESCRIPTION SYSTEM.
Advertisements

Group practice in problem design and problem solving
An Introduction to Textual Programming
General Programming Introduction to Computing Science and Programming I.
PYTHON: PART 2 Catherine and Annie. VARIABLES  That last program was a little simple. You probably want something a little more challenging.  Let’s.
1 Introduction to Flowcharting. 2 Writing a program Defining the problem –Write down what the program will do Planning –Write down the steps, draw a flowchart.
Variables. Todays Lesson  In todays lesson you are going to:  Learn to use variables  Learn to ask for user input  Learn to save the users response.
PROGRAMMING IN PYTHON LETS LEARN SOME CODE TOGETHER!
Programming Problems Intermediate 2 Computing SHOW YOUR TEACHER YOUR WORKING PROGRAM AND WRITING FRAME THEN SAVE IN YOUR PROGRAMMING FOLDER AND UPDATE.
GCSE Computing: Programming GCSE Programming Remembering Python.
COMPUTER PROGRAMMING Year 9 – lesson 1. Objective and Outcome Teaching Objective We are going to look at how to construct a computer program. We will.
Conditionals.
Part 1 Learning Objectives To understand that variables are a temporary named location to store data and that programmers work with different data types.
Input, Output and Variables GCSE Computer Science – Python.
OBJECTIVE AND OUTCOMES Objective: To be able to create images in binary format and understand the part metadata plays in recreating images. Outcomes:
Programming revision Revision tip: Focus on the things you find difficult first.
Introduction to Loop. Introduction to Loops: The while Loop Loop: part of program that may execute > 1 time (i.e., it repeats) while loop format: while.
GCSE COMPUTER SCIENCE Practical Programming using Python Lesson 4 - Selection.
GCSE COMPUTER SCIENCE Practical Programming using Python
CIS 115 Slingshot Academy / cis115.com
GCSE COMPUTER SCIENCE Practical Programming using Python
ALGORITHMS AND FLOWCHARTS
Introduction to Computing Science and Programming I
Lesson Objectives Aims To be able to write an algorithm in Pseudo Code
3.1 Fundamentals of algorithms
Repetition Structures
Data Types Variables are used in programs to store items of data e.g a name, a high score, an exam mark. The data stored in a variable is entered from.
Week of 12/12/16 Test Review.
Lesson 4 - Challenges.
IF statements.
Lesson 3 - Repetition.
Introduction to Programmng in Python
Starter Write a program that asks the user if it is raining today.
CIS115 Education for Service-- snaptutorial.com
CIS 115 Teaching Effectively-- snaptutorial.com
Lesson 1 Learning Objectives
ALGORITHMS AND FLOWCHARTS
Print slides for students reference
Control Structure Senior Lecturer
For -G7 programing language Teacher / Shamsa Hassan Alhassouni.
G7 programing language Teacher / Shamsa Hassan Alhassouni.
Python I/O.
exa.im/stempy16.files - Session 12 Python Camp
Standard Algorithms Input validation Finding the minimum
For -G7 programing language Teacher / Shamsa Hassan Alhassouni.
Javascript Game Assessment
ALGORITHMS AND FLOWCHARTS
Introduction to TouchDevelop
DO NOW – Decompose a Problem
A look at Small basic The Text Window 2017.
Python programming exercise
SCITT Day 7.
Put it all together Lesson 5.
Language Constructs Construct means to build or put together. Language constructs refers to those parts which make up a high level programming language.
Flowcharts and Pseudo Code
21 3 Variables Selection Functions Repetition Challenge 21
COMPUTATIONAL THINKING COMPUTATIONAL THINKING IN PROGRAMMING
Reading and Writing Text Files
Put it all together Lesson 6.
Functions MIS 3406 Department of MIS Fox School of Business
Programming In.
Dry Run Fix it Write a program
Starter Activities GCSE Python.
Python SAT 1 Feedback.
GCSE Computing Mini Assignment.
GCSE Computing.
Year 8 Computer Science Digital Portfolio
H446 Computer Science.
Challenge Guide Grade Code Type Slides
Presentation transcript:

GCSE COMPUTER SCIENCE Practical Programming using Python Lesson 14 – Challenges Set 1

The Challenges – Set 1 These challenges are designed to test how ready you are for the controlled assessment. There are a total of 30 challenges with varying difficulty. Each challenge tells you the lessons you need to reference to complete it successfully. EASY 9 challenges Setting Up Create a folder called Challenges Set 1 inside your C2 folder and save all the programs inside it. MEDIUM 11 challenges HARD 5 challenges VERY HARD 5 challenges

Challenge 1 Overview You will need to use: Write a program that asks the user to input their age and outputs “Your age is“ followed by their age. Sequencing Variables Difficulty EASY

Challenge 1 Code Screenshot Program Screenshot

Challenge 2 Overview You will need to use: Write a program that asks the user to input two numbers, calculates the average outputs it. Sequencing Variables Difficulty EASY

Challenge 2 Code Screenshot Program Screenshot

Challenge 3 Overview You will need to use: Write a program that asks the user to input the height and the width of a rectangle, calculates the area and outputs the result. Sequencing Variables Difficulty EASY

Challenge 3 Code Screenshot Program Screenshot

Challenge 4 Overview You will need to use: Write a program that asks the user to input two numbers, divides the first number by the second number and outputs the result. Sequencing Variables Difficulty EASY

Challenge 4 Code Screenshot Program Screenshot

Challenge 5 Overview You will need to use: Write a program that asks the user their name and then asks them what their favourite food is, using their name in the question and responds to their answer by saying you like that food as well. Sequencing Variables Difficulty EASY

Challenge 5 Code Screenshot Program Screenshot

Challenge 6 Overview You will need to use: Write a program that asks the user their name and if it is the same as your name output “You’re cool” otherwise output “I don’t like your name”. Selection Variables Difficulty EASY

Challenge 6 Code Screenshot Program Screenshot

If it is less than two hours says “That seems reasonable”. Challenge 7 Overview You will need to use: Write a program that asks the user how long, on average, they spend on a computer per day and: If it is less than two hours says “That seems reasonable”. If it is less than four hours per day says “Do you have time for anything else?” Otherwise the programs says, “You need to get some fresh air once in a while”. Selection Variables Difficulty EASY

Challenge 7 Code Screenshot Program Screenshot

A teacher needs a program that will convert marks to grades: Challenge 8 Overview You will need to use: A teacher needs a program that will convert marks to grades: If the mark is more than or equal to 75, convert it to an A. If the mark is more than or equal to 60, convert it to a B. If the mark is more than or equal to 35, convert it to a C. If the mark it less than 35, convert it to a D. Selection Variables Difficulty EASY

Challenge 8 Code Screenshot Program Screenshot

Challenge 9 Overview You will need to use: Write a program that asks the user to name one of the colours of the Olympic rings (Blue, Black, Red, Yellow and Green), if they correctly name one output “That’s correct” otherwise output “Try again”. Selection Variables Difficulty MEDIUM

Challenge 9 Code Screenshot Program Screenshot

Challenge 10 Overview You will need to use: Write a program that allows the user to play rock, paper, scissors against the computer. Selection Variables Difficulty HARD

Challenge 10 Code Screenshot Program Screenshot

Challenge 11 Overview You will need to use: Write a program that asks the user to input a sentence and then tells them how many characters there are in it. String Manipulation Variables Difficulty MEDIUM

Challenge 11 Code Screenshot Program Screenshot

Challenge 12 Overview You will need to use: Write a program that asks the user to input a sentence and outputs it in upper case. String Manipulation Variables Difficulty MEDIUM

Challenge 12 Code Screenshot Program Screenshot

Challenge 13 Overview You will need to use: Write a program that asks the user to input a sentence and outputs the number of times ‘the’ occurs in it. String Manipulation Variables Difficulty MEDIUM

Challenge 13 Code Screenshot Program Screenshot

Challenge 14 Overview You will need to use: Write a program that asks the user to input a sentence and outputs it in lower case. String Manipulation Variables Difficulty MEDIUM

Challenge 14 Code Screenshot Program Screenshot

Challenge 15 Overview You will need to use: Write a program that asks the user to input a sentence, then asks them to input the word they want to replace and word they would like to replace it with. Finally, output the sentence with the word replaced. String Manipulation Variables Difficulty MEDIUM

Challenge 15 Code Screenshot Program Screenshot

Write a program that will count from 1 to 10 using a For Loop. Challenge 16 Overview You will need to use: Write a program that will count from 1 to 10 using a For Loop. Repetition Variables Difficulty EASY

Challenge 16 Code Screenshot Program Screenshot

Write a program that will output all the odd numbers from 1 to 99. Challenge 17 Overview You will need to use: Write a program that will output all the odd numbers from 1 to 99. Repetition Variables Difficulty MEDIUM

Challenge 17 Code Screenshot Program Screenshot

Challenge 18 Overview You will need to use: Write a program that will ask the user to input a number and then outputs the times table for that number. Repetition Variables Difficulty MEDIUM

Challenge 18 Code Screenshot Program Screenshot

Challenge 19 Overview You will need to use: Write a program that uses a While Loop to make your challenge 13 program start again every time it finishes. Repetition Variables Difficulty MEDIUM

Challenge 19 Code Screenshot Program Screenshot

Challenge 20 Overview You will need to use: Write a program that asks the user to guess the number and loops until they guess 7. Then say ‘well done’. Repetition Variables Difficulty MEDIUM

Challenge 20 Code Screenshot Program Screenshot

Challenge 21 Overview You will need to use: Write a program that will allow the user to convert between centimetres and inches and vice versa. Write separate function for: Centimetres to inches Inches to centimetres Functions Selection Variables Difficulty HARD

Challenge 21 Code Screenshot Program Screenshot

Challenge 22 Overview You will need to use: Write a program that will asks the user for the distance and time that a journey was completed in. Calculate the average speed using a function. Functions Selection Variables Difficulty HARD

Challenge 22 Code Screenshot Program Screenshot

Challenge 23 Overview You will need to use: A gardener needs to buy some turf for a project they are working on. The garden is rectangular with a circular flower bed in the middle. Ask for the dimensions of the lawn and the radius of the circle. Use a function to calculate the amount of turf needed to turf the garden. Functions Selection Variables Difficulty VERY HARD

Challenge 23 Code Screenshot Program Screenshot

Challenge 24 Overview You will need to use: Write a function that takes two numbers. The first number indicates the number of spaces that should be displayed and the second number indicates the number of X’s that should be displayed. These should both be displayed on the same line. Now write another function that makes multiple calls to your first function and draws a picture with X’s. Functions Repetition Selection Variables Difficulty VERY HARD

Challenge 24 Code Screenshot Program Screenshot

Challenge 25 Overview You will need to use: Write a sign up program for an after school club, it should ask the user for the following details and store them in a file: First Name Last Name Gender Tutor Group File Handling Selection Variables Difficulty MEDIUM

Challenge 25 Code Screenshot Program Screenshot

Challenge 26 Overview You will need to use: Write a maths quiz with three questions. It must ask the user to input their name at the start. At the end it should display a message informing the user of their score. Write a function that saves the user name and quiz result in a text file. File Handling Functions Selection Variables Difficulty HARD

Challenge 26 Code Screenshot Program Screenshot

Challenge 27 Overview You will need to use: Extend your quiz program by including a list of the scores of people that have taken the quiz before. File Handling Selection Variables Difficulty VERY HARD

Challenge 27 Code Screenshot Program Screenshot

Challenge 28 Overview You will need to use: Write a random name generator that asks the user to input five names, stores them in a Data Container and outputs one of them randomly. Data Containers Repetition Variables Difficulty HARD

Challenge 28 Code Screenshot Program Screenshot

Challenge 29 Overview You will need to use: Write a program that allows the user to create a checklist for a holiday and store it. It should start by asking them the destination of the holiday, how many things they need to pack and how many tasks they need to complete to prepare. The user should then be able to enter each item they need to pack and each task they need to complete. It should be stored in a file. Data Containers File Handling Repetition Variables Difficulty VERY HARD

Challenge 29 Code Screenshot Program Screenshot

Write a function that can be reused to ask each of the questions. Challenge 30 Overview You will need to use: Improve your maths quiz by storing all the questions and answers in a two dimensional data container. Write a function that can be reused to ask each of the questions. Global Variables Functions Data Containers Repetition Difficulty VERY HARD

Challenge 30 Code Screenshot Program Screenshot