continue forward in time until all the bricks settle.
subroutine drop() !! continue forward in time until all the bricks settle. logical :: moved, tmp_moved integer(ip) :: i do moved = .false. do i = 1, n_lines call move_piece_down(i, tmp_moved) if (tmp_moved) moved = .true. ! at least one was moved end do if (.not. moved) exit ! done moving all the pieces end do end subroutine drop