Files
pplus-library/mojo/probes/input-pipe-first-line.mojo
T
alexm 568474d52f
Test (in pplus-core) / in-core (push) Failing after 28m44s
Initial commit
2026-11-12 22:23:48 -05:00

6 lines
305 B
Mojo

# probe: on piped input, what does one input() return? (the first line, without its line break and with its spaces; the rest of the pipe is read and dropped, so a second input() raises EOF: see input-lines)
# stdin: a b\nsecond\n
# expect-stdout: [a b]
def main() raises:
print("[" + input() + "]")