Take 6 numbers from the 10 numbers 0-9 to form a maximum 6-digit number divisible by 11

Take 6 numbers from the 10 numbers 0-9 to form a maximum 6-digit number divisible by 11

Set to 9876xy, the remaining 543210 is available
To be divisible by 11, the difference between odd digit sum y + 6 + 8 = y + 14 and even digit sum x + 7 + 9 = x + 16 should be divisible by 11
According to the number range
X+16-Y-14= X-Y+2 = 0
X - Y = -2
Then x = 3, y = 5, max
Such a maximum of six digits = 987635