Skip to content
Musselburgh, East Lothian, Scotland

Online coding and Python classes in Musselburgh

Which are the best online coding and Python classes in Musselburgh?

East Lothian's largest locality is Musselburgh, put at 21,100 residents by National Records of Scotland for mid-2020. Fisherrow, Inveresk, Levenhall, Monktonhall, Stoneybank and Pinkie Braes are suburbs on record in the EH21 district, and Wallyford and Whitecraig are listed there as villages. Six-year-olds through to adults of 67 study coding, Python, AI, vibe coding and maths with an India-based tutor on a live video call, alone or with a handful of classmates at the same stage. We start from algorithmic thinking, so a learner knows what a program is doing before trusting its output. There is no charge for the first lesson, and we end it by naming a course. The Musselburgh project turns 120.5 km of mapped roads into a single table giving the shortest drive between every pair of 1,124 junctions. Afterwards a place in a class is USD 100 a month, and private tuition USD 150 a month.

Old road atlases carried a triangular chart listing the distance between every pair of towns. Filling one in for a whole street network is a classic computing problem called all-pairs shortest paths. One way is to run a route-finder from every starting point in turn. Another, the Floyd-Warshall algorithm, is startlingly short: for each junction k, check whether going via k shortens the route between every pair i and j, and keep the better value. Three nested loops, and when they finish, every entry in the table is correct. This project writes it in Python, speeds it up with numpy, and runs it on Musselburgh's roads as mapped on OpenStreetMap.

Facts last verified 29 September 2026. Teaching is online; no Musselburgh branch is claimed.

Musselburgh course picks

Musselburgh courses in algorithms, Python and AI

Four ways in, arranged by age. Lesson one on any of them is live, free, and bookable without card details.

Browse the course atlas for more than one hundred options and use the coding roadmap to check prerequisites.

The four we are known for

Python, AI, vibe coding and agentic coding

These run underneath everything above. Every one is live and online, placed by ability rather than by age, and the first class is free.

Musselburgh and East Lothian

Musselburgh, Fisherrow, Inveresk and Levenhall

The NRS estimate for Musselburgh, and neighbourhoods recorded in EH21.

Musselburgh in National Records of Scotland estimates
AreaPeople
Musselburgh locality, mid-202021,100

In EH21, postcodes.io records Fisherrow, Inveresk, Levenhall, Monktonhall, Pinkie, Pinkie Braes, Stoneybank and Stoneyhill as suburban areas of East Lothian, with Wallyford, Whitecraig and Old Craighall as villages. East Lothian schools run on the Curriculum for Excellence; our tutors plan in P and S years and prepare learners for SQA Computing Science and Maths, National 5 through Advanced Higher. Holiday weeks come out of the timetable once we have the dates.

East Lothian, Edinburgh and SQA subjects

Read coding classes in East Lothian, Edinburgh and Higher Maths tuition. Why we teach reasoning before tools is on learn to think, not just use AI tools.

The Musselburgh project

A road distance chart for Musselburgh with the Floyd-Warshall algorithm

Every junction to every junction, three loops, a numpy speed-up and a cross-check.

From OpenStreetMap the learner keeps the public roads in a rectangle over Musselburgh, 120.5 km of them, and merges points where a road merely bends, leaving 1,124 junctions joined by 1,286 road segments. A 1,124 by 1,124 table starts with the length of each direct segment and infinity everywhere else. Floyd-Warshall then makes 1,124 passes: on pass k, any pair whose route would be shorter by going through junction k gets its entry lowered. That is about 1.42 billion small updates, which numpy handles in 10.1 seconds on an ordinary laptop by updating a whole row block at a time.

To be sure the table is right, the learner compares it with Dijkstra's algorithm run from a sample of junctions: every value agrees. Dijkstra from every junction would take an estimated 4.2 seconds here, so on a sparse road network the repeated single-source approach is faster, while Floyd-Warshall wins on simplicity and on dense networks. Across all pairs, the average drive between two junctions is 3.21 km and the longest shortest route, the network's diameter within the rectangle, is 10.26 km.

Part of the Musselburgh road distance chart, shortest drive in km between recorded places, our Python run on OpenStreetMap data
FromToBy roadStraight line
MonktonhallStoneybank0.4 km0.31 km
LevenhallPinkie Braes0.8 km0.41 km
FisherrowStoneyhill1.3 km0.87 km
InvereskMonktonhall3.2 km1.09 km
WallyfordMonktonhall5.1 km2.93 km

Most pairs of places are about one and a half times as far by road as in a straight line, but Inveresk to Monktonhall stands out at nearly three times. The table cannot say why; a learner would look at the map to see what the roads must go round. Distances here use public roads inside the rectangle only, so any quicker route leaving the box is not counted.

P5 to P7

Fill in a small distance chart for five places, then check whether any trip is shorter via a third.

S1 to S3

Write Floyd-Warshall in plain Python for a ten-junction map of Musselburgh streets.

S4 and up

Vectorise it with numpy for 1,124 junctions and time it against Dijkstra from every start.

OpenStreetMap roads, our table

Road geometry is from OpenStreetMap and its contributors under the Open Database Licence; place points from postcodes.io. The rectangle, the simplification, the timings and every distance are our own work, not an official route planner.

Algorithms and AI

What this teaches about vibe coding and AI agents

Short code can hide a very large amount of work.

From the Musselburgh distance chart to coding with AI
In the Floyd-Warshall projectWhen an AI writes code for you
Three loops did 1.42 billion updatesCount the work, not the lines
numpy made it take 10.1 secondsHow code runs matters as much as what it says
Repeated Dijkstra was faster hereThe textbook choice depends on the data
A cross-check confirmed every valueVerify results a second, independent way
Routes leaving the box were ignoredKnow the limits of your input

Ask an AI assistant for "distances between all places" and it will usually produce working Floyd-Warshall code in seconds, correct and possibly far too slow if written as plain Python loops. Vibe coding means the learner states what is needed and an AI drafts the code; in Musselburgh lessons the learner then times it, estimates its cost and checks a sample of answers another way before using it. AI agents that write and run code for you make these speed and correctness trade-offs silently. Agent building comes once a learner writes Python unassisted, normally in the senior years or adulthood, and Copilot Studio agents are taught in private lessons only. See how students in the UK move on to AI agents, and the reasoning in understand the code, don't copy-paste.

We have no affiliation with OpenStreetMap, National Records of Scotland or postcodes.io. Their data is open and was used as published; the analysis and any error in it belong to Modern Age Coders.

Stages

From distance charts to dynamic programming

A school year tells us roughly where to start; the free lesson pins it down.

P1 to P7

How to think

Tables, shortcuts and checking every possible route.

Problem Solving and Computational Thinking for KidsScratch Coding for Kids
P5 to S2

Vibe coding for kids

Games and small apps the learner plans and an AI helps build.

Vibe Coding for KidsPython and AI for Kids
S3 to S6

Python and algorithms

Graphs, dynamic programming and numpy alongside SQA Computing Science.

Python for TeensData Structures & Algorithms Course
Adults

Python, performance and agents

Efficient code, data work and AI agents, built step by step.

Python MasterclassGenerative AI Course
Python and graphs

What is the Floyd-Warshall algorithm, and how do you run it in Python?

Floyd-Warshall finds the shortest route between every pair of points in a network by checking, for each point in turn, whether going through it shortens any route; in Python it is three nested loops, and numpy makes it fast.

On 120.5 km of Musselburgh roads with 1,124 junctions, a numpy version filled the whole distance table in 10.1 seconds, agreeing with Dijkstra's algorithm at every checked value.

Learners who have built it ask of any code an AI hands them: how much work does this really do, and how would I check its answers?

Being able to weigh an algorithm's cost lets Musselburgh teenagers judge AI-written code instead of simply running it, which is reason enough to learn Python in 2026. The longer argument is in why teenagers should still learn to code in 2026.

How it works

Fisherrow to Wallyford, on screen

The whole set-up is a computer with a camera and an internet line good enough to stream.

Learner drives the code

Typing, prompting and running are the student's job; the tutor watches on screen share and questions every choice.

Trial finds the start

In the free session we see the current level and note any SQA exam coming up.

First session free

The opening lesson costs nothing and finishes with a course suggestion.

Classes of equals

Five to ten learners from across the UK make each group, matched by stage.

Two per week

None during Scottish school holidays.

Fixed evening

Clock changes are our tutors' problem; your lesson time does not move.

Why lessons are online

Gathering five learners of one level in one room on one evening is hard in any town. Over video it is easy.

Fees

Musselburgh fees

Musselburgh learners are charged our international rates, which cover every country outside India.

First classUSD 0

One whole lesson free, then a course suggestion.

Group tuitionUSD 100

About eight live small-class lessons per month.

Private tuitionUSD 150

About eight live one-to-one lessons per month.

All pricing is in US dollars, never sterling, and the first invoice waits until the trial has agreed a course and a regular weekly time. The pricing page explains holidays, missed sessions and moving between private and group lessons.

Reviews

East Lothian parents and UK learners, in their Google reviews

Rated 4.9 across 547 Google reviews. These are real reviews, reproduced as written.

★★★★★

"The one step solution for my son. Modern Age Coders make learning coding so simple that kids love it. The teachers explain complex concepts clearly with practical exercises and interactive content."

Ria Mukherjee

Parent

★★★★★

"Modern Age Coders has been a game-changer for me. I struggled to grasp IT concepts and coding before joining, but their classes transformed everything. I can now confidently write complex programs with ease."

Samriddha Mondal

Student

★★★★★

"One of the most wonderful education centres out there. Education is not limited to school syllabus but focuses on skill development."

Vansh Agarwal

Student

★★★★★

"My child Dhairya is really enjoying the Modern Age Coders classes. This is his first online class and he eagerly looks forward to it. I can already see his improvement, and the teachers are very cooperative."

Sonam Oswal

Parent of Dhairya

★★★★★

"Modern Age Coders have wonderful teachers who teach in a clear, easy and practical way. The teacher boosts students' confidence and inspires them to learn without hesitation."

Sonu Goyal

Parent

★★★★★

"I highly recommend this computer coding class! The teachers are incredibly knowledgeable and passionate about coding."

Ritu Kedia

Parent

Free placement class

Book a free Musselburgh lesson

Tell us the learner's age or year and one or two interests. The first session might be a distance-chart puzzle, a Scratch game planned with an AI, a first Python script, or timing two ways of solving the same problem.

+44

FAQ

Musselburgh questions

Distance tables, Floyd-Warshall, Python, vibe coding and lesson practicalities.

What is the population of Musselburgh?

National Records of Scotland estimated 21,100 people in the Musselburgh locality in mid-2020.

Do you teach online Python classes in Musselburgh?

We do, over live video, for learners aged 6 to 67 in Musselburgh, Wallyford, Whitecraig and the rest of East Lothian.

What is the difference between Floyd-Warshall and Dijkstra?

Dijkstra finds shortest routes from one starting point; Floyd-Warshall finds them between all pairs at once. On Musselburgh's sparse road network, running Dijkstra from every junction was quicker, but Floyd-Warshall is simpler to write.

What is all-pairs shortest paths?

The problem of finding the shortest route between every pair of points in a network, the computer version of a road atlas distance chart.

What does the Musselburgh project involve?

Building a road network of 1,124 junctions from OpenStreetMap, filling its complete distance table with Floyd-Warshall in numpy, and checking it against Dijkstra.

Is vibe coding taught?

Throughout, at every age: the learner plans, the AI helps draft, and the learner tests and fixes.

When can students start building AI agents?

When they write Python without help, usually senior pupils or adults; Copilot Studio agents are private lessons only.

Is there help with SQA exams?

Yes, in Computing Science and Maths from National 5 to Advanced Higher, taught for understanding with no promised grades.

What are the fees?

No charge for the trial lesson, then USD 100 a month in a class or USD 150 a month for one-to-one teaching.

What happens in the school holidays?

Lessons pause; send the dates and we plan round them.

Nearby

Other Lothians pages

Each with a different project: East Lothian (predators and prey), Edinburgh, Midlothian and Livingston (a hash tree of the map). Beyond them, go through Scotland or the UK hub.

Free classPriority demoCall us

Keep exploring Modern Age Coders

Related courses and guides

Learn more

Free resources

From the blog

Start here