      SUBROUTINE span(site,vspan,L)
*     check for existence of vertical spanning cluster
      IMPLICIT NONE
      INTEGER nbot, ntop, site(0:64,0:64), vspan, bottom, top, L
      vspan = 0
      DO bottom = 1, L
         IF(site(bottom,1) .GT. 0) THEN
            nbot = site(bottom,1)
            DO top = 1, L
               IF(site(top,L) .GT. 0) THEN
                  ntop = site(top,L)
                  IF(ntop .EQ. nbot) THEN
                     vspan = ntop
                     RETURN
                  END IF
               END IF
            END DO
         END IF
      END DO
      END
