HelpContactFor teachers and institutes
>_StemPy Lab
Mock TestsClasses

>_StemPy Lab

Learn. Solve. Code the solutions. Test yourself.

Live examsFree mock exams, timed and rankedEveryone starts together, and your score and rank come the moment it ends.See the exams →

Learn

  • Physics
  • Chemistry
  • Mathematics
  • Biology
  • Python Programming
  • Statistics & Data Science
  • Classes
  • Groups

Practice

  • Problems
  • Quizzes
  • Mock Tests
  • Prepare for an Exam
  • Question Sets
  • Exams
  • Certificates
  • Python Labs
  • AI Practice Generator
  • Student-Created Tests

Community

  • Discussions
  • Resources
  • Notes
  • Glossary
  • Blog

Account

  • Log in
© 2026 senLearn. All rights reserved.HelpFor SchoolsAboutContactPrivacy PolicyTerms of UseRefund Policy
Code it

Python Labs

Interactive, runnable Python. Edit the code, run it in your browser, no setup required.

+ Build a Lab
Pick a subject to see its topics1144 labs
The lens, the slab and the prism in code New Physics
High School (11–12) · Experimental Skills

You will write four functions for the optics experiments and the meters. They follow the lesson. The idea. For a real image, f = (uv)/(u + v). For a slab, n = ( i)/( r). For a prism at the least deviation, n = ((A + δ…

StemPy LabStemPy Lab
Purity of Mohr's salt New Chemistry
High School (11–12) · Principles Related to Practical Chemistry

You will finish a calculation of the percentage purity of a sample of Mohr's salt from a permanganate titration. The sample of 1.960 g was made up to 100.0 mL. A portion of 10.0 mL was titrated with permanganate of co…

StemPy LabStemPy Lab
Checking an answer by simulation New Mathematics
High School (11–12) · Probability

You will write a small simulation toolkit. It has a function that estimates a probability. It has one experiment, two friends who may meet. It has a test of whether an estimate is within the usual error of the exact v…

StemPy LabStemPy Lab
The egg and moult counter New Biology
High School (11–12) · Structural Organisation in Animals

You will count the eggs of a female cockroach, find the adults that you expect, and follow the length of a nymph through its moults. The idea. The eggs are the oothecae times the eggs in each. A nymph grows by a facto…

StemPy LabStemPy Lab
Fit a noisy sine Python Programming
High School (11–12), High School (9–10), Undergraduate, General · Trigonometry and Waves by Computer

You will fit a sine to 60 noisy readings of a swinging spring, with a first guess from the FFT. The idea. The FFT finds the main frequency to within one bar. curve_fit then refines the amplitude, the frequency and the…

StemPy LabStemPy Lab
A shuffling test New Statistics & Data Science
High School (9–10), High School (11–12), Undergraduate, General · Learning from Samples, Probability and Chance

You will write a shuffling test for two groups and use it on made-up data. The idea. Under the null idea of no difference, the labels mean nothing. Pool the values, shuffle, split them again and record the difference…

StemPy LabStemPy Lab
The bridge and the potentiometer in code New Physics
High School (11–12) · Experimental Skills

You will write four functions for the metre bridge and the potentiometer. They follow the lesson. The idea. On a metre bridge, (R)/(S) = (l)/(100 - l). The percentage error in R from an error Δ l in the balance point…

StemPy LabStemPy Lab
Titration readings New Chemistry
High School (11–12) · Principles Related to Practical Chemistry

You will write three small functions that turn burette readings into a concentration. Readings are in millilitres. The idea. A titre is the final reading minus the initial reading. Two titres that agree within 0.10 mL…

StemPy LabStemPy Lab
Counting dice totals New Mathematics
High School (11–12) · Probability

You will write three small functions that count the ways to get a total with several dice: the number of ways for one total, the most likely total, and the chance of a total of at most some value. The checker uses two…

StemPy LabStemPy Lab
The gut tracker New Biology
High School (11–12) · Structural Organisation in Animals

You will place the parts of the alimentary canal in their regions, add the times that food spends in the parts, and find the part where the food stays longest. The idea. The alimentary canal has a foregut, a midgut an…

StemPy LabStemPy Lab
A wave and its speed Python Programming
High School (11–12), High School (9–10), Undergraduate, General · Trigonometry and Waves by Computer

You will draw a wave of wavelength 3.0 m and frequency 4.0 Hz at two times, find its first crest each time, and work out its speed. The idea. The crest of y = A(kx - ω t) moves at the speed v = fλ. You find where the…

StemPy LabStemPy Lab
Testing a coin New Statistics & Data Science
High School (9–10), High School (11–12), Undergraduate, General · Learning from Samples, Probability and Chance

You will test a coin both ways: by simulation and by exact counting. The idea. Under the null idea, the coin is fair. The p-value is the chance that a fair coin gives at least as many heads as the real one. Your tasks…

StemPy LabStemPy Lab
Mixtures, cooling and resonance in code New Physics
High School (11–12) · Experimental Skills

You will write four functions for the experiments on heat and sound. They follow the lesson. The idea. In the method of mixtures, the heat lost by the hot block equals the heat gained by the liquid and the calorimeter…

StemPy LabStemPy Lab
Sort the cations New Chemistry
High School (11–12) · Principles Related to Practical Chemistry

You will finish a small program for the cation group scheme. A dictionary gives the group of each cation. A mixture is a list of cations. The idea. Each group reagent takes out the cations of one group. The cations th…

StemPy LabStemPy Lab
Counting with combinations New Mathematics
High School (11–12) · Probability

You will write three functions that find probabilities for draws from a group, using math.comb: the number of selections, the chance of exactly k special objects, and the chance of at least k. The checker compares the…

StemPy LabStemPy Lab
The impulse timer New Biology
High School (11–12) · Structural Organisation in Animals

You will time an impulse along a nerve fibre, choose the speed for a kind of fibre, and compare two fibres. The idea. Time is distance divided by speed. A large myelinated fibre conducts at about 100 m/s, and an unmye…

StemPy LabStemPy Lab
An identity checker Python Programming
High School (11–12), High School (9–10), Undergraduate, General · Trigonometry and Waves by Computer

You will write three small functions that check a claimed identity on many angles: one finds the worst miss between the two sides, one says whether the identity holds, and one finds an angle where it fails. The idea.…

StemPy LabStemPy Lab
How often do the intervals catch the truth? New Statistics & Data Science
High School (9–10), High School (11–12), Undergraduate, General · Learning from Samples

You will simulate many surveys from a town where the true share is known, and count how often the 95% interval catches it. The idea. Each survey asks n people. Each person says yes when a random number is below the tr…

StemPy LabStemPy Lab
Young's modulus in code New Physics
High School (11–12) · Experimental Skills

You will write four functions for Searle's experiment. They follow the lesson. The idea. For a wire of diameter d and length L, Y = (4MgL)/(π d^2 Δ L). A line through the origin fitted to the extension against the loa…

StemPy LabStemPy Lab
Name the anion New Chemistry
High School (11–12) · Principles Related to Practical Chemistry

You will write three functions that name an anion from what is seen. The observations are stored in a dictionary with three keys. The key "dilute" holds the gas with dilute sulphuric acid ("CO2", "H2S", "SO2", "NO2",…

StemPy LabStemPy Lab
Probability by listing the outcomes New Mathematics
High School (11–12) · Probability

You will write three small functions: one that finds a probability by counting outcomes, one that finds P(A B) with the addition theorem, and one that finds the probability of exactly one of two events. The checker us…

StemPy LabStemPy Lab
The heart output calculator New Biology
High School (11–12) · Structural Organisation in Animals

You will find the blood pumped in a minute, count the beats in some minutes, and name a muscle from its features. The idea. Cardiac output is the heart rate times the stroke volume. One litre is 1000 mL. Your tasks. F…

StemPy LabStemPy Lab
An angle toolkit Python Programming
High School (11–12), High School (9–10), Undergraduate, General · Trigonometry and Waves by Computer

You will write three small functions for angles: one that converts degrees to radians without math.radians, one that finds the quadrant of an angle, and one that returns the point of the unit circle at an angle. The i…

StemPy LabStemPy Lab
An interval for a proportion New Statistics & Data Science
High School (9–10), High School (11–12), Undergraduate, General · Learning from Samples

You will write the 95% interval for a proportion, with a check of its conditions. The idea. The estimate is p = countn. The margin is 1.96√(( p(1 - p))/(n)). The formula is trusted only with at least 10 successes and…

StemPy LabStemPy Lab
The best-fit line and g in code New Physics
High School (11–12) · Experimental Skills

You will write four functions for the pendulum and the straight-line graph. They follow the least-squares formulas of the lesson. The idea. The line y = mx + c through the points has the slope m = (nΣ xy - Σ xΣ y)/(nΣ…

StemPy LabStemPy Lab
Page 1 of 46
…

Showing 1–25 of 1144