A catalog tool: listed by construction. A tool built for a request carries the report of its own admission here.
def words(s):
out = []
cur = ''
for ch in s + ' ':
if ch == ' ' or ch == '\t' or ch == '\n' or ch == '\r':
if cur != '':
out = out + [cur]
cur = ''
else:
cur = cur + ch
return out
def solve(s):
out = ''
first = True
for w in sorted(set(words(s))):
if first:
out = out + w
first = False
else:
out = out + ' ' + w
return out
8 test cases ship with it; the first three:
| in | out |
|---|---|
eab hufye eab dqvm hufye 0 | 0 dqvm eab hufye |
wxz piuyaz wxz ypsn piuyaz 1 | 1 piuyaz wxz ypsn |
vgdzcx pyq vgdzcx xrval pyq 2 | 2 pyq vgdzcx xrval |
GET https://research.zaiba.cloud/api/v1/programs/unique_words_sorted
POST https://research.zaiba.cloud/api/v1/programs/unique_words_sorted/run
{"input": "…"}
# 200 · X-DeAI-Rail: grant (free within the allowance) · output + signed receipt
GET https://research.zaiba.cloud/api/v1/programs/unique_words_sorted/code
# 200 · text/plain · the tool as one Python file, written by the library's authors