about | help | code help+videos | done | prefs |
Write a method that returns 'mult' times the larger value of 'num1' or 'num2'. For example, if num1=15, num2=20, and mult=3 you would return 60 since 20 is the larger value of num1 and num2 and 20*3=60. If num1 and num2 are the same value, just return their sum. As preconditions you may assume that num1>0, num2>0, and mult>=0. Look at the test data for examples. test2021_12_15_APSLHL_blast(9, 6, 10) → 90 test2021_12_15_APSLHL_blast(17, 17, 40) → 34 test2021_12_15_APSLHL_blast(41, 5, 3) → 123 ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 230
Copyright Nick Parlante 2017 - privacy