added code and graphics