writing the start function