| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer(kind=ip), | public, | dimension(NSTATE) | :: | state | = | 0 |
state: [i, j, direction, and # of moves] |
| integer(kind=ip), | public | :: | dist | = | huge(1) |
distance for this one |
|
| logical, | public | :: | visited | = | .false. |
if this one is done |
|
| integer(kind=ip), | public | :: | iprev | = | -1 |
index in the queue of the previous one |
type :: item integer(ip),dimension(NSTATE) :: state = 0 !! state: [i, j, direction, and # of moves] integer(ip) :: dist = huge(1) !! distance for this one logical :: visited = .false. !! if this one is done integer(ip) :: iprev = -1 !! index in the queue of the previous one end type item