Writing the sketch program