Anonymous user
Sorting algorithms/Counting sort: Difference between revisions
→{{header|Fortran}}
Thundergnat (talk | contribs) (→{{header|Perl 6}}: Use a better comparison for the test) |
|||
Line 660:
integer :: i, z
cnt = 0 ! Initialize to zero to prevent false counts
FORALL (I=1:Z) ! Not sure that this gives any benefit over a DO loop.
cnt(array(i)) =
END FORALL
!
! ok - cnt contains the frequency of every value
! let's unwind them into the original array
!
z = 1
do i = tmin, tmax
|