Ichiban Prolog

1 program Added 2026-02-16T17:23:39Z Agent: claude-codeModel: sonnetWebSearch: disabled Evidence Report issue View issues
Aliases: ichiban
Provenance: commit 2dbec4f46d · authored 2026-02-16T18:25:13+01:00 · agent claude-code · model sonnet

Sources mentioning this language

1 source · not in taxonomy (canonical name didn't match any upstream)
LLM (this repo) · 1

Related languages

Prolog II (0.27)Tau Prolog (0.26)IF/Prolog (0.26)Prolog III (0.25)Ciao Prolog (0.24)

LLM-contributed programs

List Operations

Provenance: commit 2dbec4f46d · authored 2026-02-16T18:25:13+01:00 · agent claude-code · model sonnet · WebSearch disabled
code.pl · license: MIT · added: 2026-02-16T17:24:03Z
% List manipulation examples in Ichiban Prolog

% Append two lists
append([], L, L).
append([H|T], L, [H|R]) :- append(T, L, R).

% Length of a list
length([], 0).
length([_|T], N) :- length(T, N1), N is N1 + 1.

% Reverse a list
reverse([], []).
reverse([H|T], R) :- reverse(T, RT), append(RT, [H], R).

% Member check
member(X, [X|_]).
member(X, [_|T]) :- member(X, T).

% Last element of a list
last([X], X).
last([_|T], X) :- last(T, X).

% Examples
:- initialization(main).

main :-
    % Test append
    append([1, 2], [3, 4], L1),
    write('Append [1,2] and [3,4]: '), write(L1), nl,

    % Test length
    length([a, b, c, d], Len),
    write('Length of [a,b,c,d]: '), write(Len), nl,

    % Test reverse
    reverse([1, 2, 3, 4], L2),
    write('Reverse [1,2,3,4]: '), write(L2), nl,

    % Test member
    (member(3, [1, 2, 3, 4]) -> write('3 is member of [1,2,3,4]') ; write('3 is not member')), nl,

    % Test last
    last([a, b, c], Last),
    write('Last of [a,b,c]: '), write(Last), nl,

    halt.

Contribute — propose a file extension

Tell us where to find evidence about Ichiban Prolog (mapped to pl/ichiban_prolog). A reference URL is required; at least one of extension or program code must be provided too. A maintainer reviews each submission via a draft PR before anything lands.
Optional: attach a program from that URL
If the reference URL points at a single source file you'd like to add as an example program, paste it below. The workflow will write it under languages/Ichiban Prolog/programs/<sha>/. Keep under ~200 lines.
(or open the pre-filled issue directly)
← Ichi ICI →