Take an ordinary end-semester programming practical. Three sections of sixty students, one Python lab, ninety minutes each. On paper, that is 180 programs written on record sheets, and an examiner who has to decide for each one whether the code would have worked.
If reading, tracing and marking one program takes four minutes, that is twelve hours of marking for one lab, and at the end of it most of the marks are still a judgment about whether the code looks right. Some examiners run a few programs to check. Nobody runs all 180.
Run online, the same practical works differently: every student writes and runs real code, and every program is checked against the same inputs before the student has left the lab. This guide is the plan for doing that the first time, from two weeks before the exam to the marks export.
The answer a paper exam would pass
First, the reason it is worth doing. Here is a question from a first-year lab:
reverse_words(sentence), which returns the sentence with its words in reverse order. "hello world" becomes "world hello".
A student writes a program that swaps the first word with the last. Checked against the examples in the question, it is perfect: "hello world" becomes "world hello", and a one-word sentence comes back unchanged. On a record sheet it looks finished, and it would very likely get full marks.
Online, the question carries a third input the student never sees, called a hidden test case. We ran that exact program through Teemly's grader:
| Input | Seen by student? | Expected | The program returned | Result |
|---|---|---|---|---|
| hello world | Yes | world hello | world hello | Pass |
| one | Yes | one | one | Pass |
| Teemly makes coding tests | No | tests coding makes Teemly | tests makes coding Teemly | Fail |
The swap-first-and-last answer, graded. It passes every example the student can read and fails the case that tests the actual idea.
That is the whole argument for running a practical online. The marks stop depending on whether the examiner happened to try a four-word sentence. And because a student who runs this program sees that a hidden case has failed, without seeing its input, they are pushed to work out what their code gets wrong, which is the skill the lab exists to teach.
The plan at a glance
| When | What | Who |
|---|---|---|
| Two weeks before | Choose the questions and write the test cases | Subject faculty |
| One week before | Load the students and send their logins | Lab in-charge or HOD's office |
| One week before | Check the lab computers | Lab assistant |
| Two days before | Sit the paper as a student, once right and once wrong | One faculty member |
| Exam day | Invigilate, and note any interruptions | Invigilator |
| After | Review the results, run the viva, export the marks | Subject faculty |
See this in your own lab. Teemly sets coding tests from your question bank, marks every program against test cases, and explains the results in plain English. We set it up free.
Book a free demoTwo weeks before: questions and test cases
Choose fewer questions than you think. On paper a student can write three programs in ninety minutes because nothing has to run. Online, the program has to work, and making it work is most of the time. Two questions, one straightforward and one harder, is a sensible first exam.
Use the language the syllabus uses. If the course is taught in C, set the exam in C. A practical is the wrong place to discover that students cannot read a Python error message.
Write the test cases before the marks. Each question needs two or three visible cases, whose inputs and answers students can see while they work, and three to five hidden ones, whose inputs they never see. The hidden cases are where the thinking goes. For a question like "return the sum of the even numbers in a list", this is the set we use:
| Kind of case | Input | Expected | What it catches |
|---|---|---|---|
| The ordinary case | [1, 2, 3, 4] | 6 | Whether the program works at all |
| Nothing to count | [7, 9, 11] | 0 | Programs that return nothing, or crash, when there is no even number |
| A negative number | [-2, 3, 5] | -2 | Programs that only count positive numbers |
| Empty input | [ ] | 0 | Programs that assume the list has something in it |
| All of one kind | [10, 20, 30] | 60 | Programs that skip the first or last item |
Empty input, a single item, negative numbers, repeated values and the largest input the question allows: between them, those five kinds of case catch most of the mistakes a first-year student makes. There is more on choosing them, and on what each case is worth in marks, in writing hidden test cases that catch the mistakes students actually make.
One week before: students and computers
Load the students early. Each student needs their own login. The usual way is to upload the class list from Excel, with each student's email, and send the invitations from the platform. Each student opens the link in the email and sets a password.
This is the step that goes wrong, so give it a week. Some students will not find the email, some will use an address they never check, and the morning of the exam is the worst time to find out. The platform shows how many students are still waiting to activate; chase them in class.
Check the lab computers. The code runs on the platform's servers, not on the lab computers, so old machines are fine. What they do need is a working internet connection and an up-to-date browser such as Chrome or Edge. Open the platform on a few machines in each lab, especially the ones in the back row, which are usually the ones on the weakest connection.
Assign the test and set the window. Send the paper to the whole section, or only to selected students, which is how a backlog or re-test candidate sits the same paper without being added to the class. Then set when it opens, when it closes and how long each student gets.
Two days before: sit it yourself, twice
Have one faculty member sign in with a spare student account and take the paper exactly as a student will. Answer every question correctly once, and confirm every test case passes. Then answer one of them deliberately wrong, the way a weak student would, and confirm a hidden case catches it.
This takes twenty minutes and it is the most valuable twenty minutes of the whole plan. A typo in an expected answer, such as a missing space or a wrong number, fails every student who got the question right, and you would rather find it on Tuesday than in the results.
Exam day
Students sign in, read the instructions, confirm they have read them and press Start. From that moment the test runs in exam mode:
- The test goes fullscreen, and copying, pasting and right-clicking are blocked.
- Leaving the test is recorded. The first time a student leaves fullscreen or switches to another window, they get a warning. The second time, the test is submitted automatically.
- Students can run their code before submitting. They see the result of every visible case, and only a pass or fail for each hidden one, so they can find and fix their own mistakes without being handed the answers.
- When the time runs out, the test submits itself.
None of that replaces the invigilator. A browser can see that a student left the test; it cannot see a phone on the desk or a friend in the next seat. What we wrote about stopping copy-paste and tab-switching without a proctoring tool applies here in full.
The one thing the invigilator should write down is any interruption: a power cut, a computer that freezes, a student moved to another machine. Note the time and how long the student had left. That note is what makes the decision about a re-sit fair, and what to do when a student's test is interrupted mid-exam walks through it.
After: results, viva and marks
Coding answers are marked the moment each student submits. For every student, faculty can see which test cases passed and which failed, which is far more useful than a single number: a student who failed only the empty-input case understood the problem, and a student who failed every case did not.
If the paper also had written questions, those go to the faculty member to mark. The viva stays exactly where it was. In fact it gets easier, because the examiner can open the student's actual code and ask about the case it failed.
The marks then sit against each student and subject, ready to export when internal marks are due, alongside any tests the section sat on paper.
What going online changes, and what it does not
What it removes:
- The twelve hours of marking. The programs are checked as they are submitted.
- The guesswork. Every program is run against the same inputs, so a mark in section A means the same as a mark in section C.
- The examples-only answer. Code that works for the examples in the question and nothing else is caught by the hidden cases.
What it does not touch:
- The quality of the question. Weak test cases give weak marks. The two-days-before check is the only defence.
- The invigilator. Someone still has to be in the room.
- The examiner's judgment. A program that passes every case can still be badly written. The viva is where that gets marked.
Try it before you plan it
The quickest way to judge whether this would work for your students is to sit a question the way they would. There is a two-question sample test at teemly.in/try, with hidden test cases and no sign-up, which takes about five minutes.
The same setup also runs placement practice, and building a mock placement coding round with AI takes about ten minutes. When you are ready to run a real one, this is what Teemly's coding assessments are for. If your department still runs some of its practicals on a platform built for hiring, what that costs over a full semester is worth reading first.