Guest User

Increase Salary Main

a guest
Jun 18th, 2018
119
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package _002SalaryIncrease;
  2.  
  3. import java.io.BufferedReader;
  4. import java.io.IOException;
  5. import java.io.InputStreamReader;
  6. import java.util.ArrayList;
  7. import java.util.List;
  8.  
  9. /**
  10. * Created by IntelliJ IDEA.
  11. * User: LAPD
  12. * Date: 18.6.2018 г.
  13. * Time: 09:12 ч.
  14. */
  15. public class Main {
  16. public static void main(String[] args) throws IOException {
  17. BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
  18. int n = Integer.parseInt(reader.readLine());
  19.  
  20. List<Person> people = new ArrayList<>();
  21.  
  22. for (int i = 0; i < n; i++) {
  23. String[] input = reader.readLine().split(" ");
  24. people.add(new Person(input[0], input[1],
  25. Integer.parseInt(input[2]),
  26. Double.parseDouble(input[3])));
  27. }
  28.  
  29. double bonus = Double.parseDouble(reader.readLine());
  30. for (Person person : people) {
  31. person.increaseSalary(bonus);
  32. System.out.println(person.toString());
  33. }
  34. }
  35. }
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×