mirror of
https://gitlab.com/arnekeller/kit-programmieren-ws1920-final1.git
synced 2024-11-24 01:15:05 +00:00
Add script for generating codetester cases from in/out files
This commit is contained in:
parent
c0f22b2697
commit
72b76fbeb6
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +1,2 @@
|
||||
out
|
||||
testcase*
|
||||
|
16
check_from_input_output.py
Normal file
16
check_from_input_output.py
Normal file
@ -0,0 +1,16 @@
|
||||
import sys
|
||||
|
||||
fuzz = sys.argv[1]
|
||||
|
||||
input = open(fuzz + "_input.txt", "r")
|
||||
output = open(fuzz + "_output.txt", "r")
|
||||
|
||||
for line in input.readlines():
|
||||
if not line.startswith("#"):
|
||||
print(">", line, end="")
|
||||
|
||||
for line in output.readlines():
|
||||
if line.startswith("Error, "):
|
||||
print("<e")
|
||||
else:
|
||||
print(line, end="")
|
Loading…
Reference in New Issue
Block a user