Skip to content

Instantly share code, notes, and snippets.

@coderunner
Created January 14, 2012 03:04
Show Gist options
  • Select an option

  • Save coderunner/1610074 to your computer and use it in GitHub Desktop.

Select an option

Save coderunner/1610074 to your computer and use it in GitHub Desktop.
static functions
public class SalaryFunctions {
public static int computeBonus(Employee employee, float factor) {
return Math.round(employee.salary * factor * employee.targetBonus);
}
public static int getWeeklySalary(Employee employee) {
return Math.round(employee.salary / 52f);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment