summaryrefslogtreecommitdiff
path: root/python/problems/while_and_if/top_shop
diff options
context:
space:
mode:
Diffstat (limited to 'python/problems/while_and_if/top_shop')
-rw-r--r--python/problems/while_and_if/top_shop/common.py3
-rw-r--r--python/problems/while_and_if/top_shop/en.py1
-rw-r--r--python/problems/while_and_if/top_shop/sl.py6
3 files changed, 4 insertions, 6 deletions
diff --git a/python/problems/while_and_if/top_shop/common.py b/python/problems/while_and_if/top_shop/common.py
index 115dc9e..02855ec 100644
--- a/python/problems/while_and_if/top_shop/common.py
+++ b/python/problems/while_and_if/top_shop/common.py
@@ -5,7 +5,6 @@ from python.util import has_token_sequence, string_almost_equal, \
from server.hints import Hint
id = 198
-group = 'while_and_if'
number = 3
visible = True
@@ -55,7 +54,7 @@ def test(python, code):
n_correct = 0
tin = None
for i, (output, correct) in enumerate(zip(outputs, test_out)):
- if all(string_almost_equal(output, correct[i]) for i in range(2)):
+ if all(string_almost_equal(output, correct[i], prec=2) for i in range(2)):
n_correct += 1
else:
tin = test_in[i][1]
diff --git a/python/problems/while_and_if/top_shop/en.py b/python/problems/while_and_if/top_shop/en.py
index a69ae9a..b8e5119 100644
--- a/python/problems/while_and_if/top_shop/en.py
+++ b/python/problems/while_and_if/top_shop/en.py
@@ -1,6 +1,5 @@
# coding=utf-8
-id = 198
name = 'Top shop'
slug = 'Top shop'
diff --git a/python/problems/while_and_if/top_shop/sl.py b/python/problems/while_and_if/top_shop/sl.py
index ee9d02d..334736c 100644
--- a/python/problems/while_and_if/top_shop/sl.py
+++ b/python/problems/while_and_if/top_shop/sl.py
@@ -2,7 +2,6 @@
import server
mod = server.problems.load_language('python', 'sl')
-id = 198
name = 'Blagajna "top shop"'
slug = 'Blagajna "top shop"'
@@ -24,7 +23,7 @@ Poprečna cena: 2.33333333333
'''
main_plan = ['''\
-<p><b>Plan:</b></p>
+<p>Plan:</p>
<pre>
1. Ponavljaj dokler je cena večja od 0:
2. Preberi ceno.
@@ -94,7 +93,8 @@ while cena != 0:
...'''],
'final_hint': ['''\
-<p><b>Odlično!</b> Kaj bi pa moral narediti, da bi število -1 pomenilo konec?</p>''',
+<p>Odlično, program je pravilen! <br>
+Kaj bi pa moral narediti, da bi število -1 pomenilo konec?</p>''',
'''\
<p>Spremeniti pogoj in paziti,
da se vrednost -1 ne prišteje vsoti!</p>'''],