Tokbit for teachers
Tokbit is a free web app for teaching algorithms. Students build a flowchart, step through it and see how the program thinks – variables, branches and output on a retro screen. It runs in the browser on a computer, tablet or phone, with nothing to install and no sign-up.
Where next
Curriculum and ISO 5807
- Flowchart symbols are based on ISO 5807:1985, the standard for program flowcharts. For clarity we depart from it in a few places: no connectors, coloured blocks and the while loop drawn as a diamond.
- Expressions use Python syntax, so moving on to writing code comes naturally.
- Tokbit supports the Czech national curriculum (RVP ZV, Computing, lower secondary, Algorithms and programming): reading and explaining an algorithm, writing a program with loops, branches and variables, and finding and fixing errors by stepping through it.
The curriculum content explicitly names finding errors by stepping through a program and the flowchart – both are at the heart of Tokbit.
The PRIMM approach: students work with an example in five steps – predict what the program will do, run it, investigate it by stepping, modify it and finally make their own. A task identical to an example invites copying; the best check of understanding is “before each step, say what will happen”.
Run your program in Python
Programs from Tokbit also run in Python: Export → Python downloads a ZIP with the program, the tokbit.py library (MIT licence) and instructions. The window looks like the Tokbit screen.
- Install Python 3 from python.org (on a Mac use the one from python.org, not the system one; on Windows tick “Add python.exe to PATH” during installation).
- Unzip the downloaded ZIP: the whole folder, not just one file. The program and tokbit.py must be side by side.
- Open the program from the folder in IDLE (it comes with Python) and press F5, or type python3 program.py in a terminal (on Windows py program.py).
- A window with a 40 × 25 screen opens, just like in Tokbit. Without a window, only in the console: TOKBIT_TEXT=1 python3 program.py.
Contact
Author: Petr Mašek. Feedback from your lessons is welcome.