0
下面是一個代碼,我有一小塊:如何讓python添加一個字符串在一起?
studentName = ""
def getExamPoints (total):
for i in range (4):
total = 0.0
examPoints = input ("Enter exam score for " + studentName + str(i+1) + ": ")
total = ?????
total = total/.50
total = total * 100
其中?????是我無法弄清楚如何獲得字符串來添加四個分數
學生的名字我輸入後來,它是需要在程序後面我使用examPoints = getExamPoints(studentName)
。
工作完美!謝謝!!!!! – user2031682 2013-03-01 06:40:46