Results for “for”

Showing 31–40 of 136

  1. Challenge

    Command parser

    …mode safe into tuples and raises ValueError with a reason for anything malformed, then run a whole batch of commands and report each one.

    Write the code Medium 2 stages project parsing strings split
  2. Challenge

    Manifest validator

    The logistics team typed the manifest for the next supply flight by hand, and the loading crew won't touch a crate until every line checks out. Last time, a typo in a mass sent a 61 kg battery pack to…

    Write the code Medium 2 stages project validation dictionaries functions
  3. Challenge

    Edge cases

    Write assert checks for mean(): an ordinary list and a list with one value first, then the edge cases, an empty list that should give None and lists with negative values, so broken copies of the…

    Write the code Medium 2 stages testing assert edge cases None
  4. Challenge

    Parser function

    …which returns the record dict, then let it return None for blank, comment and damaged lines so the loop only keeps real records.

    Fix the code Medium 2 stages functions return dictionaries None
  5. Challenge

    Sorted copy

    Print the roster A–Z for a report with sorted() while the sign-up order stays exactly as it was, then sort names like de Vries and van Dijk correctly with key=str.lower.

    Write the code Easy 2 stages lists sorted sort key
  6. Challenge

    Alert level

    …the exact boundaries, then store the level in a variable for a status line.

    Write the code Easy 2 stages if elif else comparisons
  7. Challenge

    Sign-up cleanup

    Clean the crew sign-ups for the analogue mission: trim and capitalise names, lower-case emails, then reject sign-ups with no name or a broken email and drop duplicates by email, saying why for each…

    Write the code Medium 2 stages project strings strip split
  8. Challenge

    Test the pipeline

    …into parse_row() and check_limits(). Write assert tests for both, good rows, rejected rows and readings right at a limit, so that each of three planted bugs makes them fail.

    Write the code Hard 2 stages project testing assert try