function script test_sort {
freeloop true;
.@total = 1000;
for ( .@i = 0; .@i < .@total; .@i++ )
.@array[.@i] = rand(50);
.@start = gettimetick(0);
callfunc getarg(0), .@array, .@output, .@total;
.@end = gettimetick(0);
for ( .@i = 0; .@i < .@total; .@i++ )
.@print$[.@i] = .@array[ .@output[.@i] ];
debugmes implode( .@print$, "," );
dispbottom "time used -> "+( .@end - .@start )+" mili-seconds";
}
prontera,152,188,5 script test merge sort haru 1_F_MARIA,{
callfunc "test_sort", "merge_sort_haru";
end;
}
prontera,155,188,5 script test merge sort keyworld 1_F_MARIA,{
callfunc "test_sort", "merge_sort_index";
end;
}
prontera,158,188,5 script test counting sort 1_F_MARIA,{
callfunc "test_sort", "counting_sort_index";
end;
}
prontera,161,188,5 script test comb sort keyworld 1_F_MARIA,{
callfunc "test_sort", "comb_sort_index";
end;
}
prontera,164,188,5 script test comb sort haru 1_F_MARIA,{
callfunc "test_sort", "comb_sort_haru";
end;
}
prontera,158,185,5 script counting sort asm 1_F_MARIA,{
callfunc "test_sort", "counting_sort_index_asm";
end;
}
// callfunc "merge_sort", ,