|시간 제한||메모리 제한||제출||정답||맞은 사람||정답 비율|
|1 초||512 MB||91||34||32||41.026%|
Recall that a subsequence of a string is any string obtained by removing some subset of characters from the string, for instance “string”, “sing”, “i” and “sg” are all subsequences of “string”. If the same subsequence can be obtained in exactly t different ways, by removing different subsets of characters, we say that the subsequence occurs t times.
Jingfei wants to create a nonempty bit string that has the following properties:
However, Jingfei does not know how to create such a string – or whether it is even possible. Could you help her?
The input consists of a single line with four integers a, b, c, and d (0 ≤ a, b, c, d ≤ 109).
Output a bit string that satisfies the given requirements. If there are several solutions, output any one of them. If there are no solutions, output “impossible”.
3 4 2 1
5 0 0 5