JSON Validator and Formatter — illustrative example INPUT Input: {"active": true,} RESULT The trailing comma is invalid JSON. Corrected input: {"active": true}. REVIEW JSON validation should use a parser and report the actual error location. Formatting is separate from checking an application-specific schema. This is a teaching example, not a live execution record.