summaryrefslogtreecommitdiff
path: root/python/problems/functions/greatest_absolutist/common.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/problems/functions/greatest_absolutist/common.py')
-rw-r--r--python/problems/functions/greatest_absolutist/common.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/python/problems/functions/greatest_absolutist/common.py b/python/problems/functions/greatest_absolutist/common.py
index 2d80097..3226b87 100644
--- a/python/problems/functions/greatest_absolutist/common.py
+++ b/python/problems/functions/greatest_absolutist/common.py
@@ -6,7 +6,6 @@ from python.util import has_token_sequence, string_almost_equal, \
from server.hints import Hint
id = 196
-group = 'functions'
number = 2
visible = True
@@ -35,6 +34,10 @@ hint_type = {
def test(python, code):
+ tokens = get_tokens(code)
+ if not has_token_sequence(tokens, ['def', 'max_abs']):
+ return False, [{'id' : 'no_func_name', 'args' : {'func_name' : 'max_abs'}}]
+
test_lists = [[6, 4, 2, 0],
[4, 6, 2, 0],
[4, 2, 6, 0],