案例CS:Python案例 – Marking Crite
当前位置:以往案例 > >案例CS:Python案例 – Marking Crite
2018-04-12





Part A: Literary Scrabble [50 marks]
Part B has four supporting functions and three questions.

Word Analysis functions

Marks

Criteria

/12

def create_wordlist():

Solution:

· Opens and reads text from file.

· Strips off numbers, whitespace, punctuation and hyphens appropriately.

· Returns expected result in correct format, – sorted list of words (ascending), all lower case, no duplicate words.

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

/8

def word_match():

Solution:

· Returns expected result in correct format.

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

/8

def word_score():

Solution:

· Returns correct scrabble score per wiki reference provided.

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

/8

def find_words():

Solution:

· Code handles single and multiple letters combinations.

· Correct use of iteration to search words_list.

· Function uses helper functions word_match and word_score appropriately.

· Returns expected result.

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

Word Questions

/6

a1

Solution:

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

· Returns expected value

/8

a2

Solution:

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

· Returns expected value.

/10

a3

Solution:

· Effective and appropriate use of Python.

· Code includes useful and appropriate comments.

· Code runs without errors.

· Returns expected value.

TOTAL


在线提交订单