{ "id": "linux-exit-codes-mcq", "title": "Reading Exit Code Conventions", "category": "Linux Fundamentals", "isolation_type": "shared_namespace", "difficulty": "Easy", "type": "mcq", "weight": 3, "description": "## Reading Exit Code Conventions\n\nYou run `grep pattern file.txt` and it exits with code `1`, printing no error message at all. What actually happened?", "options": [ { "id": "a", "text": "The file doesn't exist" }, { "id": "b", "text": "grep found no lines matching the pattern — this is grep's normal way of reporting \"no match,\" not an error" }, { "id": "c", "text": "You don't have permission to read the file" }, { "id": "d", "text": "The command is broken and needs to be reinstalled" } ], "correct_option": "b", "explanation": "grep's exit code means \"did I find at least one match,\" not \"did something go wrong.\" Exit 1 with no error message is grep's normal, expected way of reporting zero matches — a very common early surprise, since silence plus a non-zero code doesn't always mean a real failure occurred.", "hints": [], "setup_commands": [], "default_namespace": "default", "teardown_commands": [] }