Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package _002SalaryIncrease;
- import java.io.BufferedReader;
- import java.io.IOException;
- import java.io.InputStreamReader;
- import java.util.ArrayList;
- import java.util.List;
- /**
- * Created by IntelliJ IDEA.
- * User: LAPD
- * Date: 18.6.2018 г.
- * Time: 09:12 ч.
- */
- public class Main {
- public static void main(String[] args) throws IOException {
- BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
- int n = Integer.parseInt(reader.readLine());
- List<Person> people = new ArrayList<>();
- for (int i = 0; i < n; i++) {
- String[] input = reader.readLine().split(" ");
- people.add(new Person(input[0], input[1],
- Integer.parseInt(input[2]),
- Double.parseDouble(input[3])));
- }
- double bonus = Double.parseDouble(reader.readLine());
- for (Person person : people) {
- person.increaseSalary(bonus);
- System.out.println(person.toString());
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement