Rivoreo Source Code Repositories
src.rivoreo.one
/
compiler-explorer
/
442c9cead43c5c603e3b8c816b972f69d9309271
/
.
/
examples
/
clean
/
qsort.icl
blob: dd51c72f3a0cbbf96e6a2c0a34d6466c84431f31 [
file
] [
log
] [
blame
] [
raw
]
module
example
import
StdEnv
qsort
::
[
Int
]
->
[
Int
]
qsort
[]
=
[]
qsort
[
p
:
l
]
=
(
qsort
[
x \\ x
<-
l
|
x
<
p
])
++[
p
]
++(
qsort
[
x \\ x
<-
l
|
x
>=
p
])
Start
::
[
Int
]
Start
=
qsort
[
3
,
5
,
1
,
4
,
2
]