Merge branch 'master' into kiram15/version
This commit is contained in:
@@ -65,7 +65,7 @@ data: |
|
||||
if response[0] == 'ac':
|
||||
for node in response[1:]:
|
||||
ac_values = node['NodeA']
|
||||
print "the ac analysis value:", ac_values
|
||||
print("the ac analysis value:", ac_values)
|
||||
if ac_values == None:
|
||||
correct = ['incorrect']
|
||||
elif ac_values[0][1] < ac_values[1][1]:
|
||||
|
||||
@@ -17,7 +17,7 @@ metadata:
|
||||
|
||||
\begin{edXscript}
|
||||
def test_str(expect, ans):
|
||||
print expect, ans
|
||||
print(expect, ans)
|
||||
ans = ans.strip("'")
|
||||
ans = ans.strip('"')
|
||||
return expect == ans.lower()
|
||||
@@ -25,7 +25,7 @@ metadata:
|
||||
def hint_fn(answer_ids, student_answers, new_cmap, old_cmap):
|
||||
aid = answer_ids[0]
|
||||
ans = str(student_answers[aid]).lower()
|
||||
print 'hint_fn called, ans=', ans
|
||||
print('hint_fn called, ans=', ans)
|
||||
hint = ''
|
||||
if 'java' in ans:
|
||||
hint = 'that is only good for drinking'
|
||||
@@ -56,7 +56,7 @@ data: |
|
||||
<customresponse cfn="test_str" expect="python">
|
||||
<script type="text/python" system_path="python_lib">
|
||||
def test_str(expect, ans):
|
||||
print expect, ans
|
||||
print(expect, ans)
|
||||
ans = ans.strip("'")
|
||||
ans = ans.strip('"')
|
||||
return expect == ans.lower()
|
||||
@@ -64,7 +64,7 @@ data: |
|
||||
def hint_fn(answer_ids, student_answers, new_cmap, old_cmap):
|
||||
aid = answer_ids[0]
|
||||
ans = str(student_answers[aid]).lower()
|
||||
print 'hint_fn called, ans=', ans
|
||||
print('hint_fn called, ans=', ans)
|
||||
hint = ''
|
||||
if 'java' in ans:
|
||||
hint = 'that is only good for drinking'
|
||||
|
||||
Reference in New Issue
Block a user