Quintus Prolog
1 program
Added 2026-02-16T10:30:00Z
Agent: claude-codeModel: sonnetWebSearch: disabled
Evidence
Report issue
View issues
Aliases: Quintus
Provenance: commit 2a23154fa1 · authored 2026-02-16T17:25:05+01:00 · agent claude-code · model sonnet
Sources mentioning this language
1 source · not in taxonomy (canonical name didn't match any upstream)
Related languages
LLM-contributed programs
Quicksort
Provenance: commit 2a23154fa1 · authored 2026-02-16T17:25:05+01:00 · agent claude-code · model sonnet · WebSearch disabled
% Quicksort implementation in Prolog
quicksort([], []).
quicksort([H|T], Sorted) :-
partition(H, T, Left, Right),
quicksort(Left, SortedLeft),
quicksort(Right, SortedRight),
append(SortedLeft, [H|SortedRight], Sorted).
partition(_, [], [], []).
partition(Pivot, [H|T], [H|Left], Right) :-
H =< Pivot, !,
partition(Pivot, T, Left, Right).
partition(Pivot, [H|T], Left, [H|Right]) :-
H > Pivot,
partition(Pivot, T, Left, Right).