Coding Sheet
Programming from zero
Programming basics in Python, Java or C++ for people who have never written code. Every exercise has a worked solution in Python, Java and C++. Tick each one off as you go.
49
By difficulty
Easy34
Medium15
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| First steps theory + first problem: print a service status messageDevOps, SRE | Easy | Read | ||||
| Print a server's hostname and IP from variablesDevOps, SRE | Easy | Read | ||||
| Swap the active and standby serversDevOps, SRE | Easy | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Types and operators theory + first problem: comparing disk usage between two serversDevOps, SRE | Easy | Read | ||||
| Check if a port number is even or oddDevOps, SRE | Easy | Read | ||||
| Convert disk usage in bytes to GBDevOps, SRE | Easy | Read | ||||
| Calculate an uptime percentageDevOps, SRE | Easy | Read | ||||
| Convert seconds into hours, minutes, and secondsDevOps, SRE | Easy | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Strings theory + first problem: build a health check URLDevOps, SRE | Easy | Read | ||||
| Normalize a config valueDevOps, SRE | Easy | Read | ||||
| Split a log line into its partsDevOps, SRE | Medium | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| If and else theory + first problem: alert when a service is stoppedDevOps, SRE | Easy | Read | ||||
| Classify CPU usage as OK, warning or criticalDevOps, SRE | Easy | Read | ||||
| Decide if a deploy is allowedDevOps, SRE | Medium | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Loops theory + first problem: print every port from 8000 to 8010DevOps, SRE | Easy | Read | ||||
| Count down before a restartDevOps, SRE | Easy | Read | ||||
| Add up disk usage across serversDevOps, SRE | Easy | Read | ||||
| Retry a connection until it succeedsDevOps, SRE | Medium | Read | ||||
| Find the first server matching a conditionDevOps, SRE | Easy | Read | ||||
| Print a deployment matrix of environments and regionsDevOps, SRE | Medium | Read | ||||
| Print a port availability grid for a list of hostsDevOps, SRE | Medium | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Arrays and lists theory + first problem: get the first and last serverDevOps, SRE | Easy | Read | ||||
| Find the highest response timeDevOps, SRE | Easy | Read | ||||
| Filter a list to only web serversDevOps, SRE | Easy | Read | ||||
| Remove duplicate IPs while keeping orderDevOps, SRE | Medium | Read | ||||
| Count how many times a value appears in a listDevOps, SRE | Easy | Read | ||||
| Sort servers by response timeDevOps, SRE | Easy | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Dictionaries and maps theory + first problem: read values from a config dictionaryDevOps, SRE | Easy | Read | ||||
| Use a default when a config key is missingDevOps, SRE | Easy | Read | ||||
| Count how many servers are in each regionDevOps, SRE | Medium | Read | ||||
| Group hosts by health statusDevOps, SRE | Medium | Read | ||||
| Iterate over a config dictionary's keys and valuesDevOps, SRE | Easy | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Sets and tuples theory + first problem: find unique client IPs from a request listDevOps, SRE | Easy | Read | ||||
| Check whether a server is in an allow-listDevOps, SRE | Easy | Read | ||||
| Store a server record as a tuple and access each valueDevOps, SRE | Easy | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Functions theory + first problem: write is_valid_port(n)DevOps, SRE | Easy | Read | ||||
| Build hostnames with a default environmentDevOps, SRE | Easy | Read | ||||
| Format uptime seconds as days, hours, minutesDevOps, SRE | Medium | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Files theory + first problem: count the lines in a log fileDevOps, SRE | Easy | Read | ||||
| Write a server inventory fileDevOps, SRE | Easy | Read | ||||
| Extract error lines into a new fileDevOps, SRE | Medium | Read | ||||
| Parse a CSV server inventory into a list of dictionariesCloud, DevOps, SRE | Medium | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Errors and exceptions theory + first problem: convert a port from text safelyDevOps, SRE | Easy | Read | ||||
| Handle a missing config file without crashingDevOps, SRE | Medium | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Classes and objects theory + first problem: create a Server class with hostname, IP, and statusDevOps, SRE | Easy | Read | ||||
| Add a restart method to the Server classDevOps, SRE | Easy | Read |
| Status | Problem | Difficulty | Practice | Explanation | Solution | Save |
|---|---|---|---|---|---|---|
| Build a service health report from a list of serversDevOps, SRE | Medium | Read | ||||
| Analyze a log file and count entries by levelDevOps, SRE | Medium | Read | ||||
| Validate a configuration dictionary against required fieldsDevOps, SRE | Medium | Read |
Must-do problem (the last-minute revision list). Company tags appear only where a public interview report names that company.