Initial data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 72d218235f
commit f23f22d71c
199087 changed files with 3378941 additions and 0 deletions

View file

@ -0,0 +1,13 @@
import strutils
proc removeComments(line: string; sep: char): string =
line.split(sep)[0].strip(leading = false)
const
Str1 = "apples, pears # and bananas"
Str2 = "apples, pears ; and bananas"
echo "Original: “$#" % Str1
echo "Stripped: “$#" % Str1.removeComments('#')
echo "Original: “$#" % Str2
echo "Stripped: “$#" % Str2.removeComments(';')