Create parser.v

This commit is contained in:
2026-07-11 12:20:11 +02:00
parent 95376d5cc8
commit 5a24afb267
2 changed files with 8 additions and 3 deletions
+1 -3
View File
@@ -1,5 +1,3 @@
module main
import os import os
fn read_stdin() []string { fn read_stdin() []string {
@@ -16,5 +14,5 @@ fn read_stdin() []string {
fn main() { fn main() {
lines := read_stdin() lines := read_stdin()
println(lines) println(parse(lines))
} }
+7
View File
@@ -0,0 +1,7 @@
fn parse(lines []string) string {
mut output := ''
for _, line in lines {
output += line + '\n'
}
return output
}