CGI interview question

Write stack program. Class pointer, DBMS query, malloc calloc, oops concept