J
Jorgen Grahn
void selectionSort(char s[], int len); int findSmallest(char s[], const
int idx_cur, const int len);The consts on those parameters don't do much, but aren't actually wrong.
Just to show that function is not supposed to change its arguments.
That makes sense in the /definition/ of the function, provided you
want them to be const just like you might want any local variable to
be const.
It does not make sense in the /declaration/. The compiler will just
go "of course you can't change the argument, stupid -- C uses call by
value!"
/Jorgen