CGI Interview Question

Gave three coding questions..need to compile and run successfully