Added output to q5.cpp
Added output to q5.cpp