TSS '19 CC P1 - Counting Pieces

View as PDF

Submit solution


Points: 3
Time limit: 2.0s
Memory limit: 64M

Author:
Problem type

jsumabat wants to play chess with his brother! Sadly, his chessboard only contains the black pieces of the board, and are missing a few. The set of black pieces should include:

1 king, 1 queen, 2 rooks, 2 bishops, 2 knights, 8 pawns

jsumabat wants to know how many pieces he needs to add or remove to make it a proper set.

Input Specification

The first line of input will contain the number of kings, queens, rooks, bishops, knights, and pawns, respectively.

Output Specification

Output how many pieces, for each type of piece, will he need to add or remove.

Sample Input 1

0 1 2 2 2 7

Sample Output 1

1 0 0 0 0 1

Sample Input 2

2 1 2 1 2 1

Sample Output 2

-1 0 0 1 0 7

Comments

There are no comments at the moment.