On this page
article
Files & JSON Exercise #12
Practice files & json — exercise 12 of 30.
Topic: Files & JSON
Difficulty: Intermediate
Problem
Write a solution for Files & JSON Exercise #12:
Implement a function solve_files_12(data) that processes the input according to files & json concepts from the curriculum.
Example input: data = [files & json_example_12]
Expected: A transformed result demonstrating files & json skills.
Constraints
- Use idiomatic Python 3.10+
- Handle empty input gracefully
- Do not mutate input unless specified
Hint
Hint
Review Files & JSON exercises and the related chapter in the Learning Path. Consider edge cases: empty collections, None, zero, negative numbers.
Test Yourself
# Write tests before implementing
assert solve_files_12([]) is not None # define expected behavior
Next exercise: Files & JSON Exercise #13