Almost the same as what Goofballtech had
int flag = true; if (flag){ // Do some stuff; flag = false; }
Rob