Create square using iterator