while and for loop declarations implemented