Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package day4HomeWork;
- public class KalkulatorOsigorovki {
- public static void main(String[] args) {
- double c = 3000; //zaplata
- int n = 55; //godini
- double m = 0.0;
- if (n <= 55) { //do 55
- m = (20 + 17) * c / 100;
- } else if (n <= 60) { //do 60
- m = (13 + 13) * c / 100;
- } else if (n <= 65) { //do 65
- m = (7.5 + 9) * c / 100;
- } else { //nad 65
- m = (5 + 7.5) * c / 100;
- }
- System.out.println(m);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement