##Student Name: Wurong Weng
##MacID: wengwr
##Student Number: 1224989
##Date: March 6, 2013

##Implement makeCeteredRow function
def makeCenteredRow(w, c):
    return w/2 * ' ' + c

##Implement makeRow function
def makeRow(a, b ,c):
    return ' ' * a + c + ' ' * b + c

##Implement makeCross function
def makeCross(w,c):
    result = []
    for i in range(w/2):
        result.append(makeRow(i, w-2-2*i, c))
    result.append(makeCenteredRow(w,c))
    for i in range(w/2-1, -1, -1):
        result.append(makeRow(i, w-2-2*i, c))
    return result


##Design Qusetion:
##    if using conditional statements in makeCross function, first have to test if
##    the row number is less than the half of the total line, the space between the
##    character(c) is decreasing, and if the row number is greater than the half of
##    row line, the space between the character(c) is increasing.
##    the conditionals would make the implementation less complex to read and understand.

##Test Plan:
##    Test 1 for makeCenteredRow(w,c)
##    Input: [(7, '#')]
##    Expected Output: [['   #']]
##    Actual Output: [['   #']]
##    Result: PASS
##
##    Test 1 for makeRow(a, b, c)
##    Input: [(7, 8, '#')]
##    Expected Output: [['       #        #']]
##    Actual Output: [['       #        #']]
##    Result:PASS
##
##    Test 1 for makeCross(w,c)
##    Input: [(9, '#')]
##    Expected Output: [['#       #', ' #     #', '  #   #', '   # #', '    #', '   # #', '  #   #', ' #     #', '#       #']]
##    Actual Output: [['#       #', ' #     #', '  #   #', '   # #', '    #', '   # #', '  #   #', ' #     #', '#       #']]
##    Result: PASS
