subject

Since you love games of chance, you've decided to participate in a dice-rolling competition. The competition involves rolling three 6-sided dice, and the results of each die are represented by the integers a, b, and c respectively. Scores are calculated according to the following rules: If all three dice had the same value (a = b = c) then you earn 1000 * a.
If exactly two of them are the same, you earn 500 * x (where x is the value of the two equal dice).
If all of them are different, you earn 100 * min(a, b, c).
Given the values of a, b, and c, your task is to calculate and return your total score.
Example
For a = 3, b = 3, and c = 3, the output should be diceTotalScore(a, b, c) = 3000.
Since all of the dice have the same value, your total score is equal to 1000 * 3 = 3000.
For a = 3, b = 6, and c = 3, the output should be diceTotalScore(a, b, c) = 1500.
Since exactly two of the values are the same (a = c = 3), your total score is equal to 500 * 3 = 1500.
For a = 3, b = 2, and c = 5, the output should be diceTotalScore(a, b, c) = 200.
Since all of these values are different, your total score is equal to 100 * min(a, b, c) = 100 * 2 = 200.
Input/Output
[execution time limit] 4 seconds (py3)
[input] integer a
An integer representing the value of the first die.
Guaranteed constraints:
1 ≤ a ≤ 6.
[input] integer b
An integer representing the value of the second die.
Guaranteed constraints:
1 ≤ b ≤ 6.
[input] integer c
An integer representing the value of the third die.
Guaranteed constraints:
1 ≤ c ≤ 6.
[output] integer
Return your total score
Pleasee use Python
def diceTotalScore(a, b, c):

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 13:00
Donnie does not have powerpoint. which method would be best for elana to save and share her presentation as is? a pdf a doc an rtf a ppt
Answers: 3
question
Computers and Technology, 23.06.2019 14:00
Select the correct answer. a company is currently focusing on creating specific management goals for itself. which level of maturity is the company demonstrating under the sse_ccm framework? a. performed informally b. planned and tracked c. quantitatively controlled d. well-defined e. continuously improving
Answers: 2
question
Computers and Technology, 23.06.2019 18:30
How often does colleges update the cost of attendance on their website? . a)every two years b) every four years c) every year d) every semester
Answers: 1
question
Computers and Technology, 23.06.2019 22:20
If i uninstall nba 2k 19 from my ps4 will my career be gone forever?
Answers: 2
You know the right answer?
Since you love games of chance, you've decided to participate in a dice-rolling competition. The com...
Questions
question
Mathematics, 31.07.2019 15:30
question
Mathematics, 31.07.2019 15:30
question
Mathematics, 31.07.2019 15:30
Questions on the website: 13722360