如何拖放quizz?

时间:2015-06-04 20:51:40

标签: openedx

GUI很难获得示例代码。特别是:

correct_answer = {
        '1':      [[100, 150], 100],
        '2':      [[300, 150], 100],
        '3':      [[500, 150], 100],
        '4':      [[700, 150], 100]}

如何理解和使用它?

1 个答案:

答案 0 :(得分:0)

记录there。 困难的部分是'id': [[x coordinate, y coordinate], radius]

<problem>
Recreate the sentence : `Demain, je vais marche`.
   <customresponse>
        <drag_and_drop_input img="https://studio.edx.org/c4x/edX/DemoX/asset/L9_buckets.png">
            <draggable id="1" label="I"/>
            <draggable id="3" label="walk"/>
            <draggable id="4" label="tomorrow"/>
            <draggable id="2" label="will"/>
        </drag_and_drop_input>
        <answer type="loncapa/python">
correct_answer = {
        '1':      [[100, 150], 100],
        '2':      [[300, 150], 100],
        '3':      [[500, 150], 100],
        '4':      [[700, 150], 100]}
if draganddrop.grade(submission[0], correct_answer):
    correct = ['correct']
else:
    correct = ['incorrect']
        </answer>
    </customresponse>
</problem>
相关问题