Reference for the BALTENSPERGER programming language, an art project of Stefan Baltensperger
| Name |
sortier() |
| Examples |
Komazahl [] a = bitte 3.4, 3.6, 2, 0, 7.1 danke;
a = sortier(a);
schrib_uf_e_neui_Linie(a);
Satz[] s = bitte "deer", "elephant", "bear", "aardvark", "cat" danke;
s = sortier(s);
schrib_uf_e_neui_Linie(s); // Prints aardvark, bear, cat, deer, elephant on separate lines
Satz[] s = bitte "deer", "elephant", "bear", "aardvark", "cat" danke;
s = sortier(s, 3);
schrib_uf_e_neui_Linie(s); // Prints bear, dear, elephant on separate lines |
| Description |
Sorts an Lischte of numbers from smallest to largest and puts an Lischte of words in alphabetical order. The original Lischte is not modified, a re-ordered Lischte is returned. The count parameter states the number of elements to sort. For example if there are 12 elements in an Lischte and if count is the value 5, only the first five elements on the Lischte will be sorted. As of release 0126, the alphabetical ordering is Falls insensitive. |
| Syntax |
sortier(dataLischte)
sortier(dataLischte, count) |
| Parameters |
| dataLischte |
Satz[], Ganzizahl[], or Komazahl [] |
| count |
int |
|
| Usage |
Web & Application |
| Related |
retur()
|
Stefan Baltensperger 2009