Python3 code bank for KS4, core reference for NEA

This 5* rated resource does NOT contain complete solutions for OCR NEA 2018 - 2020.

But what it does contain are clearly presented code snippets, designed to help reinforce application of programming knowledge, helping students to understand code and create their own solutions without giving up hope, in a relatively short space of time.

I’ve been programming, and teaching for a long time, and understand that some students can struggle to code. This one-stop shop aims to give students the confidence to work out their own solutions from this one easily-accessible reference guide.

This resource shows how to complete tasks such as file handling; in the most straightforward way possible. File handling needn’t be complicated. I’ve seen some trying to use SQL, CSV or JSON formatted data. This often leads to needless confusion amongst those just starting their programming journey. None of this is necessary. This resource shows you how to use simple code to manage files…and much much more.

This resource helps students to have those ‘eureka’ moments as they piece together ideas and get to grips with programming (it can also help staff!)

It is clearly presented and contains enough ideas to help students to feel good about being able to code their own solution.

…Python3 code bank for KS4 Quick reference guide with adaptable code snippets…

Covers…

  • File handling
  • Iterating over dictionaries
  • Iterating through numbers
  • Input
  • Print (and formatting technique)
  • Generic game loop
  • Generic login
  • Random shuffling
  • Random number generation
  • Removing items from a list
  • Adding items to a list
  • Modulus arithmetic operator
  • Thinking about using primitives or lists
  • Dictionaries
  • Len function
  • String methods: lower(), title()
  • Sorting a list of dictionaries
  • Casting integers to strings
  • Generic menu code: showing use of functions
$3.24
Save for later
  • python3-code-bank.pdf

About this resource

Info

Created: Sep 11, 2018

Updated: Nov 6, 2018

Worksheet

pdf, 143 KB

python3-code-bank

Report a problem