id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

abraskin@mbusd.org chapter1exam > averageFIs65
prev  |  next  |  chance

When calculating an average of three scores, sometimes a grade of F or below (a score of 65 or less) is automatically just an F so the score is counted as a 65 unless the score is recorded as a 0. Return the average of three scores, but if fIs65 is true then any score less than 65 should be counted as 65 unless it is a 0.


averageFIs65(100, 0, 50, false) → 50
averageFIs65(100, 0, 50, true) → 55
averageFIs65(100, 3, 50, false) → 51

...Save, Compile, Run (ctrl-enter)

public int averageFIs65(int a, int b, int c, boolean fIs65) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 150

Copyright Nick Parlante 2017 - privacy