Challenge
Telemetry pipeline
…flag, save. Validate the rows Read telemetry.csv with csv.DictReader . Reject a row whose sensor is not in LIMITS , or whose value is not a number, with its line number in the file: the header is line…
Showing 21–30 of 35
Challenge
…flag, save. Validate the rows Read telemetry.csv with csv.DictReader . Reject a row whose sensor is not in LIMITS , or whose value is not a number, with its line number in the file: the header is line…
Challenge
…the level counter from "Entries per level": replace the dict and counts.get() with collections.Counter, which starts every key at 0, then list the levels from most to least common with most_common().
Quiz
…values: 15 questions on return, None, several values, lists, dictionaries and early exit. Instant answers.
Challenge
…with in, fix it with get() and a default, then print a list of launches with defaults for any missing field.
Challenge
…09:33:05 COMMS Signal weak (x2) Keep the groups as dicts in a list, groups , with first , last , source , message and count , and a dict from (source, message) to the newest group for that alert…
Challenge
…every contact window longer than 8 minutes into one list, sorted by time, then find the longest stretch with no station in contact, counting overlapping passes only once.
Article Python Fundamentals
…= True engines_active = False Complex Data Types Lists Ordered collections of items, great for storing sequences of data: planet_names = ["Mercury", "Venus", "Earth", "Mars"] temperatures = [167, 464…
Challenge
…two weeks in a sealed habitat, has closed, and the list is a mess: names in capitals or with double spaces, emails with stray spaces, people who signed up twice, an entry with no name at all. Clean it…
Challenge
…output exactly as it is now: parse_feed(feed) returns a dict from each sensor to its list of values, as floats, in order; summary_line(sensor, values) returns one report line: the average rounded to…
Quiz
…of the earlier quizzes, from variables and strings to lists, dictionaries and functions. For each piece of code you decide which error it raises, read the message, or choose the fix. What the quiz…