summaryrefslogtreecommitdiff
path: root/python/problems/functions/greatest
diff options
context:
space:
mode:
Diffstat (limited to 'python/problems/functions/greatest')
-rw-r--r--python/problems/functions/greatest/common.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/python/problems/functions/greatest/common.py b/python/problems/functions/greatest/common.py
index 6857603..e6b7139 100644
--- a/python/problems/functions/greatest/common.py
+++ b/python/problems/functions/greatest/common.py
@@ -32,6 +32,10 @@ hint_type = {
}
def test(python, code):
+ tokens = get_tokens(code)
+ if not has_token_sequence(tokens, ['def', 'max_val']):
+ return False, [{'id' : 'no_func_name', 'args' : {'func_name' : 'max_val'}}]
+
test_lists = [[6, 4, 2, 0],
[4, 6, 2, 0],
[4, 2, 6, 0],