Reformatted code and added help button