Python challenges for A level Computer Science
149 Python programming challenges for A level Computer Science, in the order the course teaches them. Each one opens in the simulator with a starting program, and it is marked the moment you press Run: the robot either does the job or you are told what is missing.
A1. Programming techniques and object-oriented programming
- Readings as a record type Decide the three fields first and what type each one holds. Then one definite loop does the looking: read, build a record, add it to the array, turn a quarter. A second… Lesson A1.1
- Drive a command string Each command is one letter followed by a number. Separate the commands, then take the first character as the letter and everything after it as the amount. Distances add… Lesson A1.2
- A distance that cannot crash the program Put the conversion and the range check inside one function, so both kinds of bad input end up as the same exception. The loop keeps asking until a call succeeds. Think… Lesson A1.3
- Survey by reference A list passed to a subroutine is the same list the caller has, so the procedure can fill it without returning anything. For the nearest, keep the best index and the… Lesson A1.4
- Fix the scope bug Read the error message: it names the variable and says it is local. The function only needs the count in and the new count out, so give it a parameter and a return… Lesson A1.5
- Structure it from the hierarchy chart Write the subroutines at the bottom of the chart first, and test each one alone. Each box becomes one subroutine, and each line down from a box is a call inside it. The… Lesson A1.6
- The odometer class Each object needs its own name and its own running total, so both belong in the constructor. drive(cm) does the driving and adds to that object's total only. Think… Lesson A1.7
- Behaviours by inheritance The base class already has a name and an act method. Each subclass passes its own name up to the base constructor and overrides act with what it does. The loop at the… Lesson A1.8
- A rover made of parts Decide which part belongs to the rover alone and which one it only uses. The part it owns is created inside its constructor; the part it uses is made outside and handed… Lesson A1.9
- Project: the behaviour controller Get the base class and one behaviour working before the controller. The controller's job each step is the same: go through the behaviours in priority order and let the… Lesson A1.10
A2. Recursion and computational thinking
- Watch the call stack Every subroutine needs the same two jobs: one at its first line and one just before it ends. Write those two jobs once as helpers. The depth is simply how many frames… Lesson A2.1
- Down and back up Decide what echo(0) does on its own, with no further call. For any bigger n, the work splits into three parts: something before the call on the smaller problem, the… Lesson A2.2
- A recursive spiral Find the smallest side that should not be driven: that is the base case. Every other call drives one side, turns, and hands a slightly smaller spiral to itself. Check… Lesson A2.2
- Binary, both ways The last binary digit of n is its remainder when divided by 2, and the other digits are the binary of n divided by 2 (whole-number division). For recursion, that is the… Lesson A2.3
- A grid model of the mat Work out the centre of each cell from its row and column first, remembering that row 0 is the top of the mat, where y is largest. A cell is blocked if its centre is… Lesson A2.4
- Swap the insides Decide what the three questions need, rather than what the readings were: how many there have been, what they add up to, and the smallest so far. A new log starts those… Lesson A2.5
- A route built from pieces Write the smallest piece first and test it on one leg. A shape is only a list of legs, so driving it is the smaller piece used once per item; a route is a list of… Lesson A2.6
- Routes with a cache Before any calculation, look the pair up in the cache and hand back the stored answer if it is there. After calculating, store the answer before returning it. The… Lesson A2.7
- Who won the race? Four runners can finish in only 24 orders, so test them all. For each order, turn it into a place for each name, then write each clue as a condition on those places. An… Lesson A2.7
- Getting ready at the same time A job cannot start until every job it needs has finished, so its earliest finish is its own time added to the latest finish among the jobs it needs. A job that needs… Lesson A2.8
- Two jobs, one processor Neither job may wait for the other. Start driving without waiting, then go round one loop many times a second. Each time round, give each job a quick turn: check… Lesson A2.8
- Mining the run log First find which speeds appear in the log, without assuming. Then, for each one, pick out the runs at that speed and total their bumps. Keep track of the best mean seen… Lesson A2.9
- Nearest first Keep a list of the stops not yet visited and where the robot is now. Each time, measure the across-plus-up distance to every unvisited stop, choose the smallest, add it… Lesson A2.9
- Solve the maze model Write the checks that end a call straight away first: off the grid, a block, or a cell already visited. Then mark the cell and add it to the path. If it is the goal you… Lesson A2.10
- Out of the dead end Solve the model first; the robot only moves once the path is known. Then turn each cell into a point in cm from where the robot started: S is (0, 0), each column is 20… Lesson A2.10
A3. Data structures
- The depth cube Three nested loops reach every reading: the outer one picks the scan, the middle one the row, the inner one the column. Keep a running total for each scan, and keep the… Lesson A3.1
- Undo back home Push a move before you make it, and only make it if the push worked. To undo, keep popping until the stack is empty, doing the opposite of each move. One last pop after… Lesson A3.2
- The command queue Work out what happens to rear when it is already at the last slot: it must come back to 0. A count of items is the easiest way to tell a full queue from an empty one,… Lesson A3.3
- The linked route To delete, find the node before E and point it past E, then put E's slot on the front of the free list. To insert, take the slot at the front of the free list, fill it,… Lesson A3.4
- Markers in a hash table The home slot is the key MOD 11. If that slot is taken, try the next one, wrapping from 10 back to 0. A search follows exactly the same path and counts every slot it… Lesson A3.5
- Commands by name Split the message into words and take them two at a time. A dictionary from each direction word to its direction vector means one look-up replaces four comparisons;… Lesson A3.6
- Meet on the line The dot product multiplies matching components and adds the results. The angle comes from rearranging u.v = |u||v| cos(angle), and each length is the square root of a… Lesson A3.7
- Update the master file Keep one position in each file. Compare the two current ids: the smaller one is written first and only its file moves on. When the ids match, write one record with the… Lesson A3.8
- Mission control Load every line into the queue before you move. Then take commands off the front one at a time: a move is looked up in the dictionary, made, pushed onto the stack, and… Lesson A3.9
A4. Trees and graphs
- Degrees and the handshake Every edge touches two vertices, so each edge adds one to the degree of both of its ends. Keep a count per vertex, then add up the counts and the weights. Lesson A4.1
- Matrix and list The matrix needs a row and a column for every vertex, starting full of zeros; each edge sets the one cell in its from-row and to-column. The list gives each vertex its… Lesson A4.2
- What can be reached Mark a vertex visited the moment you arrive, then try its neighbours in the order the list gives them, going as deep as you can down each before trying the next.… Lesson A4.3
- A breadth-first visit Put A in a queue and mark it discovered. Repeatedly take the zone at the front, visit it, and add each neighbour not yet discovered to the back. The queue decides the… Lesson A4.4
- Facts about a tree The root is the one node that is nobody's child. A leaf is a node with no children. The height of a node is 0 for a leaf, otherwise one more than the tallest of its… Lesson A4.5
- A search tree in arrays A new key goes in the next free index with no children. Then start at the root and follow left or right pointers, comparing as you go, until the pointer you want to… Lesson A4.6
- Three ways round a tree Each traversal visits the left subtree, the right subtree and the node itself; only the moment the node is written down changes. To work out the value, each operator… Lesson A4.7
- Plan the route Build the adjacency list first: each free square is joined to the free squares directly above, below, left and right of it. Breadth-first search from A, remembering for… Lesson A4.8
A5. Algorithms and complexity
- The growth table Loop over the five values of n. For each one, copy n into another variable and keep halving the copy while it is bigger than 1, counting as you go. Build the line from… Lesson A5.1
- Brute force routes n! multiplies every whole number from 1 up to n, so start a total at 1 and multiply it in a loop. For the years: divide the number of orders by the orders checked per… Lesson A5.1
- Count the steps Give each function a counter that starts at 0 and goes up by one every time the marked line runs, and return the counter at the end. has_duplicate never finds a repeat… Lesson A5.2
- Recursive binary search Two base cases come first: low has passed high (not there), or the middle item is the target. Otherwise call the function again on the half that could hold the target,… Lesson A5.3
- Count the comparisons Put the counter next to each comparison of two items, not next to each swap. In insertion sort, check that j is still 0 or more before comparing, and stop the inner… Lesson A5.4
- Merge sort the readings Split the list at the middle, sort each half with a call to merge_sort, and add up the comparisons both calls report. Then merge: count one comparison each time you… Lesson A5.5
- Place the pivots Partition first: walk j from low to high - 1, swapping each item smaller than the pivot into position i and moving i on, then swap the pivot into position i. That… Lesson A5.6
- The shortest route table Start every distance at infinity and the start at 0. Repeatedly take the unvisited vertex with the smallest distance, and for each unvisited neighbour see whether going… Lesson A5.7
- Round the rough ground Keep a heap of (f, h, row, col) entries and a dictionary of the best g for each square. Each time round, pop the smallest, skip it if it is already closed, close and… Lesson A5.8
- Plan the route, then drive it Make an empty neighbour dictionary for every waypoint, then add each road to both of its ends with its length. Run Dijkstra's algorithm from S, follow the previous… Lesson A5.9
A6. Theory of computation
- Ends in 01 Each state should remember how much of 01 the machine has just read: nothing useful, a 0, or 01. For each state, ask where a 0 takes it and where a 1 takes it. Only one… Lesson A6.1
- Search, approach, stop Copy the six rows of the table into the dictionary first. Then each tick needs only four things: turn the sensors into one input symbol, look up the pair of state and… Lesson A6.2
- Two robots' sightings Turn each list into a set first, so the repeats disappear. Each line is then one set operation or one comparison. To print a set in the required form, put it in order… Lesson A6.3
- Three languages For L1, fix the first and last symbols and let anything go between. For L2, think of the string as built from blocks, where a block is either a lone 0 or a 1 with its… Lesson A6.4
- Check robot programs Follow the BNF: each function tries its rule's alternatives at position i. A command is a move if the character there is a direction letter, or a repeat if it is an… Lesson A6.5
- An RPN calculator For to_rpn, follow the five steps of the shunting-yard algorithm, giving * and / a bigger precedence number than + and -. Remember an opening bracket on the stack must… Lesson A6.6
- The delivery route For the heuristic, keep a list of the points not yet visited and where you are now; each step, pick the unvisited point closest to where you are, move there and cross… Lesson A6.7
- The watchdog Keep a count of steps taken. Loop while the count is below the limit: if the program is done, report the count and return straight away; otherwise take a step and add… Lesson A6.8
- Add one in binary Adding 1 starts at the rightmost digit, but the head starts at the left, so the first state's job is to move right until it finds the blank, then step back. A second… Lesson A6.9
- The mission Do it in stages and test each: first the loop that keeps asking until the mission is valid; then one visit with the machine; then a loop over the ids. Add every id from… Lesson A6.10
A7. Data representation
- Any base Divide by the base again and again. Each remainder is one digit, and the first remainder you get is the rightmost digit, so build the string from the right. Decide what… Lesson A7.1
- Kilo or kibi Work out the size of one frame in bits first, then in bytes. Decimal prefixes divide by a power of 1,000 and binary prefixes by a power of 1,024. A minute of video is… Lesson A7.1
- A signed adder Work from the rightmost column to the left, adding the two bits and the carry in. The column's bit is the total mod 2 and the new carry is the total divided by 2.… Lesson A7.2
- Decode a float The mantissa's place values start at -1 and then halve: 1/2, 1/4, 1/8 and so on. The exponent is an ordinary two's complement integer with -8 as its first place value.… Lesson A7.3
- Store a reading Scaling by 256 moves the binary point eight places, so the whole part of metres times 256 is the stored pattern. Dividing the stored whole number by 256 gives back the… Lesson A7.4
- Unpack a colour Shift the 16-bit value right until the field you want sits at the bottom, then AND it with a mask of that field's width. To widen a field, shift it left to fill the new… Lesson A7.5
- Checksums on the radio Add up the character code of every character and keep only the remainder after dividing by 256, so it fits in one byte. To check a packet, split it at the star,… Lesson A7.6
- Vector to bitmap For every pixel, take the point in the middle of it and test it against each shape: inside a rectangle means between its left and right edges and between its top and… Lesson A7.7
- Play the MIDI events Every 12 note numbers is an octave, and an octave doubles the frequency, so the frequency is 440 times 2 to the power of how many twelfths the note is above note 69.… Lesson A7.8
- A compressed route Walk the words in order. The first time you meet a word, add it to the end of the dictionary; every time, write down its position in the dictionary. Decoding looks each… Lesson A7.9
- A one-time pad XOR each message byte with the key byte in the same position. Because XOR with the same key byte twice gives back what you started with, one function both encrypts and… Lesson A7.9
- A secure sensor packet Build the four bytes one at a time: the type letter's code, the reading doubled to keep one fraction bit, the flags from shifted 1s ORed together, and the checksum of… Lesson A7.10
A8. Boolean algebra and logic circuits
- Everything from NAND NOT and AND are worked out in the lesson. For OR, think about what a NAND gives when both of its inputs have already been inverted. For XOR, sketch it on paper first:… Lesson A8.1
- Truth table to expression Row number i, written as three binary digits, is the values of A, B and C on that row. For each row whose output is 1, turn each digit into a letter or NOT and a… Lesson A8.2
- Prove it by brute force Two expressions are equal only if they agree on every row, so loop through all eight combinations in binary order and stop at the first row where they differ. Return… Lesson A8.3
- De Morgan at the wall De Morgan turns NOT (X OR Y) into (NOT X) AND (NOT Y). Apply it to the loop condition, and remember that NOT (distance < 20) can also be written as a comparison the… Lesson A8.4
- Simplify, then prove it Work on paper first. Apply De Morgan to the bracket with NOT in front, then look for two terms that differ only in one letter being inverted, and for a letter that can… Lesson A8.5
- Draw the map, read the groups The rows and the columns both go in Gray code order, so neighbours differ by one bit. Print the map first and look at it: find the biggest groups of 1s, remembering… Lesson A8.6
- A 4-bit ripple carry adder Add from the rightmost bit, which is the last character of each string, and pass each carry out into the next column's carry in. The first column has a carry in of 0.… Lesson A8.7
- A D-type flip-flop Keep the clock's previous value in a variable so you can spot the moment it goes from 0 to 1. Q only takes the value of D at that moment and holds it at every other… Lesson A8.8
- Project: the robot's safety logic Put the five rows on a four-variable Karnaugh map in Gray code order and find the fewest, largest groups; then see whether factoring out a shared literal, or De Morgan,… Lesson A8.9
A9. Computer architecture
- Bus widths Each wire carries one bit, so ask how many different patterns a given number of bits can make. The smallest unsigned value is all zeros; the largest is all ones, which… Lesson A9.1
- The flags Work out the full sum first: carry is whether it went past what 8 bits can hold, and the stored result is only the part that fits. For overflow, read both inputs and… Lesson A9.2
- Fetch in register transfers Follow the fetch table: where does the address come from, what moves the PC on, which register receives what memory sends back, and where must the instruction go so the… Lesson A9.3
- Four ways to read an operand For each mode, ask how many times memory is looked up and with which address. Immediate needs no look-up, direct one, indirect uses the result of one look-up as the… Lesson A9.4
- The larger of each pair Plan it in pseudocode first. The loop starts by reading the first number and leaving if it is zero. To find the larger, subtract one from the other and let the sign of… Lesson A9.5
- Decode the control bytes Draw the byte as eight boxes. Work out which way and how far to shift so only the speed bits are left, and which mask keeps only the bottom two bits. The mode number… Lesson A9.6
- A timer interrupt The check belongs after the main program's work in each cycle, not before it. Count the interrupts in a separate variable. A stack gives back the last thing pushed… Lesson A9.7
- A pipeline, tick by tick Number the instructions and the stages from 0. At a given tick, work out which instruction number each stage would hold by counting back from the tick, and check… Lesson A9.8
- How much flash does a camera need? An image is a list of rows, so the number of rows and the length of a row give the pixel count. Bytes per frame follows from bytes per pixel. For the flash, find the… Lesson A9.9
- Build the processor Build it in the order of the steps and test after each one. Write one helper that turns an operand into a value, so immediate and direct addressing are handled in one… Lesson A9.10
A10. Operating systems, software and translators
- The software audit Decide which kinds of software exist to run and look after the computer, and which exist to do a job for the user. Keep running counts in the same loop that prints each… Lesson A10.1
- The driver table Store each driver function in a dictionary under its device name. The system call only has to check the name is a key, then call whatever function it finds there with… Lesson A10.2
- Paging The page number is how many whole pages fit before the address, and the offset is what is left over. A page fault is a page whose table entry is empty: fill the entry… Lesson A10.3
- Nested interrupts Keep three things for the running routine: its name, its priority and its next instruction. At the end of each cycle, first deal with a routine that has just finished,… Lesson A10.4
- Waiting times For SJF, whenever the processor is free, choose only from the processes that have already arrived, and run the chosen one to the end. For SRT, step the clock one unit… Lesson A10.5
- A bytecode virtual machine Every instruction either pushes values, pops values, or changes the program counter. For the arithmetic ones, remember the second value popped was pushed first, which… Lesson A10.6
- An LMC assembler The first pass only needs to notice labels and remember which address each is on. The second pass looks up the opcode for each mnemonic and adds the operand, which is… Lesson A10.7
- A lexer Look at one character at a time and let it decide what kind of token is starting. Digits and letters can go on for several characters, so keep reading while the next… Lesson A10.8
- Project: a tiny robot OS Build it in layers: first the drivers table, then the round-robin loop with no interrupt, and check the order of the lines. Only then add the check after every step.… Lesson A10.9
A11. Databases and big data
- The degree of a relationship For each left value, collect the set of right values it is paired with, and the other way round. If any left value has more than one partner, the right-hand side is… Lesson A11.1
- A composite key Neither field is unique on its own, but the pair is. Declare that pair as the key when you create the table, then try every insert and let the database tell you which… Lesson A11.2
- Normalise the score sheet Ask, for each non-key field, which key it depends on. A set of tuples throws away the repeats for you, and sorting a set of tuples sorts by the first field, then the… Lesson A11.3
- Build it, then join it Create the parent tables before the table that refers to them. The query has to travel from runs to robots to teams, so it needs two joins, each matching a foreign key… Lesson A11.4
- Log the legs, keep the links Switch the checking on before anything else touches the database. Measure each leg from position() before and after it. The refusal and the vanishing of Bolt's run… Lesson A11.5
- All or nothing Do the increase first and the decrease second, as the task says, so a refused move has already changed one row by the time it fails. The only way the totals stay right… Lesson A11.6
- Timestamp ordering Keep two dictionaries, the latest read timestamp and the latest write timestamp of each record, both starting at 0. A read is too late if a younger transaction has… Lesson A11.7
- Three formats, one set of readings Collect the readings once, as a list of dictionaries, and write all three formats from that one list. For the CSV, the header comes once, before the loop. Reading the… Lesson A11.8
- Map, shuffle, reduce The mapper sees one line and knows nothing else: it gives back a list of key and value pairs, empty for a line that is not a bump. The shuffle gathers every value with… Lesson A11.9
- What was true then The state at a time is built only from facts with a timestamp no later than that time. Go through those facts oldest first, so that a later fact about the same robot… Lesson A11.9
- The run database Design first: four entities, and runs is the one with two foreign keys. The robot is Ada, robot 1. Measure each run from position() before and after, rounded to a whole… Lesson A11.10
A12. Networks and the web
- Frame a byte Get the character's code, write it as eight bits, then reverse them so the least significant bit goes first. Put the start bit in front and the stop bit after. Count… Lesson A12.1
- Wait for a quiet channel Listen for a short window. If anything arrived, the channel is busy: say so, wait a random time and listen again. Only when a whole window is silent do you ask to send,… Lesson A12.2
- Put the packets back together Split each packet at the first colon, then split the header at the slash to get its number and the total. Keep the payloads in a dictionary by number until you hold as… Lesson A12.3
- Wrap it and unwrap it Write one function that works out a checksum for any text and use it both ways: to build your packet, and to check the reply. To unwrap the reply, split off the… Lesson A12.4
- Local or through the router? Turn a dotted address into one 32-bit number and back again, so the mask, network and broadcast addresses become single bitwise operations. Two addresses are on the… Lesson A12.5
- Get an address Write one helper that waits for a reply starting with a given word and hands back its fields. Use it after each message you send. The offer tells you what to request;… Lesson A12.6
- The NAT table Keep two dictionaries: one from a private socket to the public port it was given, and one back the other way. An outgoing packet from a socket you have not seen gets… Lesson A12.6
- A stateful firewall Check the rules in the order they are listed and stop at the first that matches. An outgoing packet is remembered as a connection; an incoming packet is a reply only if… Lesson A12.7
- The robot as a REST server Split each request into its method, its path and anything after. Keep the resources in variables: the LED colour, and a dictionary of moves by number. Decide the… Lesson A12.8
- Index and rank Work every new rank from the old ranks, not from ranks you have already updated this round: build a fresh dictionary each iteration. A page's share of its vote is its… Lesson A12.9
- A reliable link Only a packet whose checksum matches may be stored or acknowledged; a damaged one gets a NAK with its number and is thrown away. Keep listening until you hold every… Lesson A12.10
A13. Functional programming
- Make it pure A pure function can only use its parameters. For the count, think about the empty tuple first, then how the count for a whole tuple relates to its first item and the… Lesson A13.1
- The compass type Work out a way to turn any whole number of degrees into a quarter number 0 to 3, so the four ranges line up with N, E, S and W; check the edges 44, 45, 314 and 315. For… Lesson A13.2
- The command table Start with the table: each letter needs a function of one number. make_turn has to hand back a function it has just made, so decide which robot command that inner… Lesson A13.3
- Calibrate by composition Each of scale and offset returns a function that is still waiting for its cm. compose returns a function too. Remember which argument of compose is applied first, then… Lesson A13.4
- Analyse the sweep Work in stages, printing each one as you go: the parsed tuples, the valid ones, and so on. Each stage is a new value made from the one before. For the nearest, the… Lesson A13.5
- There and back Every recursive function here has the same shape: what is the answer for the empty tuple, and how is the answer for a whole tuple made from its head and the answer for… Lesson A13.6
- Count the fleet's events Test merge on its own first with two small dictionaries, including an event that is only in one of them. The keys of the new dictionary are every key in either. Once… Lesson A13.7
- The way out Build and test the pure part first with made-up readings, as in steps 2 and 3, before the robot moves at all. Then add the sweep, and check that the pairs it returns… Lesson A13.8
A14. Software development, law and ethics
- The feasibility study The weighted score is the total of score times weight, divided by the total of the weights. Find the blockers first, because a proposal with a blocker fails whatever… Lesson A14.1
- Plan the sprints Deal with the stories that are bigger than a whole sprint first. Then keep a list of the stories in the sprint you are filling and its running total; when the next… Lesson A14.2
- Meet the success criteria Approach fast while the wall is far away, then creep in small steps so you cannot overshoot the band. Take the measurements once the robot has stopped, and let an if… Lesson A14.3
- Print the structure chart A module's line is its name after some spaces that depend on its depth. After printing it, do the same for each of its sub-modules one level deeper. A module that is… Lesson A14.4
- Test the black box Write the expected result for each test from the specification alone, before you look at the code. The boundaries are where the result changes, so test the value on… Lesson A14.5
- The commit log Count how many times each line appears in the old version and in the new one; a line appearing more often in the new version was added that many times, and one… Lesson A14.6
- Keep the log lawful Work through the records in order. First decide whether a record is too old to keep; if it is, count it and move on. For a kept record, look the name up in the key,… Lesson A14.7
- Explain every decision Each time round the loop, read the gap and decide from it which of the three decisions applies. Keep the last decision in a variable, and only print and change the LED… Lesson A14.8
- The delivery robot Build it in the order of the design: write gap_ok and test it before the robot moves, then approach, then the sidestep and signal, and evaluate last. Keep a count of… Lesson A14.9
A15. Exam preparation
- The timing plan Turn the start time into minutes after midnight first, so all the arithmetic is on whole numbers. The time per mark comes from the time left after checking divided by… Lesson A15.1
- Level the answers Split each answer into sentences first. Decide for each sentence whether it is the conclusion, whether it makes a point, and whether that point is developed, and which… Lesson A15.2
- Trace the search Print the row as soon as mid has been worked out, before comparing, so every comparison has a row. Then decide which half the target must be in, and move low or high… Lesson A15.3
- There and back with a stack Translate the pseudocode one method at a time, keeping its structure. Drive each move of the route and push it as you go. To come back, pop a move, drive the opposite… Lesson A15.4
- Shortest route, then drive it Keep a distance for every node, starting at infinity except the start, and a record of which node each best distance came from. Repeatedly take the unvisited node with… Lesson A15.5
- Change the skeleton program Read the whole skeleton before changing anything, and find where each change belongs. Do the checks in move in the order given, and leave the method as soon as one… Lesson A15.6
- Theory at speed For two's complement, the leftmost bit is worth minus the place value it would normally have. The mantissa has its binary point just after the sign bit, so its value is… Lesson A15.7
- The revision scheduler Keep two dictionaries: the box each card is in, and the day each card is next due. On each day, go through the cards in order and review only those due today, updating… Lesson A15.8
Questions
Are these Python challenges free?
Yes. Every challenge runs in the browser with nothing to install.
How are the challenges checked?
The simulator runs your program and checks what the robot did and what it printed against the challenge's goals. If something is missing it says what, so you can fix it and run it again.
Are there solutions?
There is no answer to copy. Each challenge has a Stuck? button that tells you what to work out next, and the lesson it comes from teaches everything the challenge needs.
What order should I do them in?
Top to bottom. They follow the course, so each section only needs what the sections before it taught.