Advertisement
Guest User

Untitled

a guest
May 5th, 2015
219
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.68 KB | None | 0 0
  1. import java.util.*;
  2. import java.io.*;
  3.  
  4.  
  5. public class Cholsterol
  6. {
  7. final int LEVEL = 125;
  8. public static void main(String[] args)
  9. {
  10.  
  11. System.out.println(getStatus(LEVEL));
  12.  
  13. }
  14.  
  15. static String getStatus(int input)
  16. {
  17. if(input < 100)
  18. {
  19. return "optimal";
  20. }
  21. if((input > 101) &&(input < 129))
  22. {
  23. return "near optimal";
  24. }
  25. if((input > 129) &&(input < 159))
  26. {
  27. return "Borderline High";
  28. }
  29. if((input > 159) &&(input < 189))
  30. {
  31. return "High";
  32. }
  33.  
  34. return "Very High";
  35. }
  36. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement