Can anyone help me to do this Question

You are given three integers a, b and . Your task is to construct a binary string s of length n=a+b such that there are exactly a zeroes, exactly b ones and exactly x positions i (1≤i<n) such that si≠si+1. It is guaranteed that the answer always exists.

Recall that binary string is a non-empty sequence of characters where each character is either 0 or 1.

Input
The first line of the input contains three integers a, b and x(1≤a,b≤100,1≤x<a+b).

Output
Print only one string s, where s is any binary string satisfying conditions described above. It is guaranteed that the answer always exists.

Examples
input
2 2 1
output
1100

input
3 3 3
output
101100

input
5 3 6
output
01010100

Note
All possible answers for the first example:

1100;
0011.
All possible answers for the second example:

110100;
101100;
110010;
100110;
011001;
001101;
010011;
001011.
What is the problem you're encountering?
What don't you understand?
What have you tried and what is your code so far?

People won't do things *for* you on here, however we are more than happy to help on the foundation of what you've already done.
As hoogo said, show your attempt at the problem then people would gladly help you accomplish your task.
Topic archived. No new replies allowed.