Challenge
Mission config
Predict, investigate and extend a mission config held in variables: text, whole numbers, decimals and True/False. A PRIMM challenge on Python data types.
Showing 1–10 of 21
Challenge
Predict, investigate and extend a mission config held in variables: text, whole numbers, decimals and True/False. A PRIMM challenge on Python data types.
Challenge
…a battery through one orbit. A PRIMM challenge on updating variables.
Challenge
…using or, then name the rule that fired with boolean variables and an if/elif chain.
Challenge
…a quick calculation for the cargo module and called the variables a , b , x2 and tmp . The program works, but nobody, including its author a month from now, can tell what it calculates without working…
Challenge
…assigns to fuel_kg inside the function, creating a local variable and leaving the global fuel unchanged. Predict the last line, compare both values, fix it by returning the total, then write a…
Challenge
Unpack an (id, item, mass_kg) tuple into three named variables and print a cargo manifest line, then fix the ValueError when the manifest adds a fourth field.
Challenge
Turn the bare 9.81 and 1000 in a weight report into named constants without changing the output, then write a Mars version with constants from the start.
Challenge
…landing site as a (lat, lon) tuple, unpack it into two variables in one line and print both to four decimals, then show it the way maps do, with N, S, E and W.
Challenge
…each value to the type it should have, into the new variables named in the comments, then print each new value and its type: altitude_km: 408 <class 'int'> speed_kms: 7.66 <class 'float'> crew: 3…
Challenge
…check the exact boundaries, then store the level in a variable for a status line.