Question: How do I stop this error? scoreln = int ( input ( ) ) ValueError: invalid literal for int ( ) with base 1 0
How do I stop this error?
scoreln intinput
ValueError: invalid literal for intwith base :
I want to be able to add decimal inputs
scores
scoresGTEListing
scoresLTListing
sum
i
scoreln
printEnter a score or negative number to exit:
scoreln intinput
while scoreln :
scoresiscoreln
sum sum scoreln
i i
printEnter a score or negative number to exit:
scoreln intinput
print
average sum i
scoresGTECtr
scoresLTCtr
printTotal scores entered: stri
for index in rangei:
if scoresindexaverage:
scoresGTECtr scoresGTECtr
scoresGTEListing scoresGTEListing strscoresindex
else:
scoresLTCtr scoresLTCtr
scoresLTListing scoresLTListing strscoresindex
printAverage score: straverage
printNumber of scores greater than or equal to the average: strscoresGTECtr
printThe scores greater than or equal to the average are: scoresGTEListing
print
printNumber of scores less than the average: strscoresLTCtr
printThe scores less than the average are: scoresLTListing
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
