NumPy allowed · plain Python earns 10 bonus points
Implement recursive JSON serialization from scratch supporting nested objects, lists, escaping, and primitives.
Implement custom_json_serializer(data): serialize Python primitives (None -> null, bool -> true/false, numbers, strings with escaped quotes/newlines, lists, and dicts) into standard JSON syntax without using the standard library json module.
custom_json_serializer(data: any) -> str