Skip to content

Commit 296fd40

Browse files
committed
Added time limit constraints
1 parent 5482714 commit 296fd40

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

automate.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ g++ -std=c++11 checker.cpp -o checker
55
g++ -std=c++11 output_checker.cpp -o outputgen
66
counter=5
77
while [[ $counter -gt 0 ]]; do
8-
./inputgen
9-
./work
10-
./checker
8+
timeout 2s ./inputgen
9+
timeout 2s ./work
10+
timeout 2s ./checker
1111
line=$(./outputgen)
1212
echo $line
1313
if [[ ${line:0:1} != 'S' ]]; then

automate_p.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ g++ -std=c++11 -O2 tester.cpp -o tester
55
g++ -std=c++11 -O2 precision_checker.cpp -o precisionc
66
counter=1
77
while [[ $counter -gt 0 ]]; do
8-
./inputg
9-
./result
10-
./tester
8+
timeout 2s ./inputg
9+
timeout 2s ./result
10+
timeout 2s ./tester
1111
line=$(./precisionc)
1212
echo $line
1313
if [[ ${line:0:1} != 'S' ]]; then

0 commit comments

Comments
 (0)