Rearrange the digits in ⟨1263045⟩ to meet the rules below.
⟨6th 5th 4th 3rd 2nd 1st 0th⟩
✅Match
6th → a, 1st → b, |a-b|=3
2nd → 0|3
⟨? ⋯ 6 ⋯ (?+3) ⋯⟩ (?≠3)
max ⊢0⊣ ≤ 4
max ⊢3⊣ = 3
#125034_v2.5
┌───┬───┬───┬───┬───┬───┬───┐
│6th│5th│4th│3rd│2nd│1st│0th│▒
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡▒
Step 1 │ │ │ │ │ 0 │ │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 2 │ │ │ │ │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 3 │ 1 │ │ │ │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 4 │ 1 │ 6 │ │ │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 5 │ 1 │ 6 │ │ 3 │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 6 │ 1 │ 6 │ 2 │ 3 │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 7 │ 1 │ 6 │ 2 │ 3 │ 0 │ 4 │ 5 │▒
└───┴───┴───┴───┴───┴───┴───┘▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
Proof of 2024-05-14 Q1(m=6)
═══════════════════════════
Notation: if nth -> a, then we write [nth] = a.
By ✅「⟨? ⋯ 6 ⋯ (?+3) ⋯⟩ (?≠3)」, we have [6th] = 0|1|2. Actually [6th] != 0, for otherwise it follows from ✅「6th → a, 1st → b, |a-b|=3」 that
┌───┬───┬───┬───┬───┬───┬───┐
│ 6▲│5th│4th│3rd│2nd│ 1▲│0th│
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡
│ 0 │ │ │ │ │ 3 │ │
└───┴───┴───┴───┴───┴───┴───┘
But then we cannot match ✅「2nd → 0|3」, which is a contradiction.
Hence, we have
(1) [6th] = 1|2.
Combining this with ✅「6th → a, 1st → b, |a-b|=3」, we see that one of the following holds:
┌───┬───┬───┬───┬───┬───┬───┐
│ 6▲│5th│4th│3rd│2nd│ 1▲│0th│
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡
(2) │ 1 │ │ │ │ │ 4 │ │
├───┼───┼───┼───┼───┼───┼───┤
(3) │ 2 │ │ │ │ │ 5 │ │
└───┴───┴───┴───┴───┴───┴───┘
No matter which case happens, if we place 3 at 2nd, then we cannot match ✅「max ⊢3⊣ = 3」. So, in view of ✅「2nd → 0|3」, we get [2nd] = 0 as our first step:
┌───┬───┬───┬───┬───┬───┬───┐
│6th│5th│4th│3rd│ 2■│1st│0th│▒
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡▒
Step 1 │ │ │ │ │ 0 │ │ │▒
└───┴───┴───┴───┴───┴───┴───┘▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
--- Idle ---
┌───┬───┬───┬───┬───┬───┬───┐
│ 1 │ 2 │ 6 │ 3 │ │ 4 │ 5 │
└───┴───┴───┴───┴───┴───┴───┘
It then follows from ✅「max ⊢0⊣ ≤ 4」 that case (3) does not hold. Therefore, case (2) holds, and we get
┌───┬───┬───┬───┬───┬───┬───┐
│ 6■│5th│4th│3rd│2nd│ 1■│0th│▒
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡▒
│ │ │ │ │ 0 │ │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 2 │ │ │ │ │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 3 │ 1 │ │ │ │ 0 │ 4 │ │▒
└───┴───┴───┴───┴───┴───┴───┘▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
--- Idle ---
┌───┬───┬───┬───┬───┬───┬───┐
│ │ 2 │ 6 │ 3 │ │ │ 5 │
└───┴───┴───┴───┴───┴───┴───┘
Next, we consider how to place 6. Plainly, there are four possibilities:
(4) 6 = [5th] | [4th] | [3rd] | [0th].
We proceed to show that 6 is at 5th.
------------------------------
(4.1) By ✅「⟨? ⋯ 6 ⋯ (?+3) ⋯⟩ (?≠3)」, we need 6 is between 1 and 4, so 6 != [0th].
(4.2) On the other hand, to match ✅「max ⊢0⊣ ≤ 4」, we cannot have 6 = [3rd].
(4.3) If 6 = [4th]:
┌───┬───┬───┬───┬───┬───┬───┐
│6th│5th│ 4▲│3rd│2nd│1st│0th│
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡
│ 1 │ │ 6 │ │ 0 │ 4 │ │
└───┴───┴───┴───┴───┴───┴───┘
--- Idle ---
┌───┬───┬───┬───┬───┬───┬───┐
│ │ 2 │ │ 3 │ │ │ 5 │
└───┴───┴───┴───┴───┴───┴───┘
then we have no way to match ✅「max ⊢3⊣ = 3」. So, we have 6 != [4th] as well.
------------------------------
Combining (4), (4.1), (4.2), and (4.3), we conclude that 6 = [5th]:
┌───┬───┬───┬───┬───┬───┬───┐
│6th│ 5■│4th│3rd│2nd│1st│0th│▒
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡▒
│ 1 │ │ │ │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 4 │ 1 │ 6 │ │ │ 0 │ 4 │ │▒
└───┴───┴───┴───┴───┴───┴───┘▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
--- Idle ---
┌───┬───┬───┬───┬───┬───┬───┐
│ │ 2 │ │ 3 │ │ │ 5 │
└───┴───┴───┴───┴───┴───┴───┘
Then, observe that to match ✅「max ⊢3⊣ = 3」, there is only one way to place 3:
┌───┬───┬───┬───┬───┬───┬───┐
│6th│5th│4th│ 3■│2nd│1st│0th│▒
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡▒
│ 1 │ 6 │ │ │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 5 │ 1 │ 6 │ │ 3 │ 0 │ 4 │ │▒
└───┴───┴───┴───┴───┴───┴───┘▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
--- Idle ---
┌───┬───┬───┬───┬───┬───┬───┐
│ │ 2 │ │ │ │ │ 5 │
└───┴───┴───┴───┴───┴───┴───┘
Finally, applying ✅「max ⊢3⊣ = 3」 once more, we finish by
┌───┬───┬───┬───┬───┬───┬───┐
│6th│5th│ 4■│3rd│2nd│1st│ 0■│▒
╞═══╪═══╪═══╪═══╪═══╪═══╪═══╡▒
│ 1 │ 6 │ │ 3 │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 6 │ 1 │ 6 │ 2 │ 3 │ 0 │ 4 │ │▒
├───┼───┼───┼───┼───┼───┼───┤▒
Step 7 │ 1 │ 6 │ 2 │ 3 │ 0 │ 4 │ 5 │▒
└───┴───┴───┴───┴───┴───┴───┘▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
--- Idle ---
┌───┬───┬───┬───┬───┬───┬───┐
│ │ │ │ │ │ │ │
└───┴───┴───┴───┴───┴───┴───┘
Q.E.D.
#125034_v2.5