Here is the Diagnostics helper script. I manually produced 2.txt, ... 6.txt using the "Copy all items to clipboard" feature in
Anagrams version 2.08. Those files are saved in a separate folder containg the "elevenplustwo.txt" and the following script. Then I ran the script.
Code: Select all
#NoEnv
#SingleInstance, Force
;---------------------------------------------------------------------------
; split elevenplustwo.txt MD5 = 9e2d9e30887c75d12137fc5c076644f3
;---------------------------------------------------------------------------
FileRead, TXT, elevenplustwo.txt
Loop, Parse, TXT, `n, `r
{
Line := Trim(A_LoopField)
StrReplace(Line, A_Space,, Count), Count++
OUT%Count% .= Line "`r`n"
}
For each, Index in [2,3,4,5,6] {
FileDelete, % "ref " Index ".txt"
FileAppend, % RTrim(OUT%Index%, "`r`n"), % "ref " Index ".txt"
}
;---------------------------------------------------------------------------
; sort "ref x.txt" for x = 2,3,4,5,6 as proposed by Helgef
;---------------------------------------------------------------------------
For each, Index in [2,3,4,5,6] {
FileDelete, % "ref " Index " sorted.txt"
FileRead, TXT, % "ref " Index ".txt"
Output := ""
Loop, Parse, TXT, `n, `r
{
Line := A_LoopField
Sort, Line, D%A_Space%
Output .= Line "`r`n"
}
Output := RTrim(Output, "`n`r")
Sort, Output
FileAppend, %Output%, % "ref " Index " sorted.txt"
}
;---------------------------------------------------------------------------
; sort "x.txt" for x = 2,3,4,5,6 as proposed by Helgef
;---------------------------------------------------------------------------
For each, Index in [2,3,4,5,6] {
FileDelete, % Index " sorted.txt"
FileRead, TXT, % Index ".txt"
Output := ""
Loop, Parse, TXT, `n, `r
{
Line := A_LoopField
Sort, Line, D%A_Space%
Output .= Line "`r`n"
}
Output := RTrim(Output, "`n`r")
Sort, Output
FileAppend, %Output%, % Index " sorted.txt"
}
ExitApp
Now I compare
2 sorted.txt with
ref 2 sorted.txt and so on. My first observation when I compare
6 sorted.txt and
ref 6 sorted: (used for brevity)
There are lines that all start with "el el " which come from
Anagrams that are not present in the reference, all remaining differences are lines in the reference, but are missing from
Anagrams output.
Needs further investigation, I just share my method here already, Maybe we can get an idea where to look next?
Edit: Second impression: all lines starting with "el el " are only present in
Anagrams output, not present in the reference.
5 sorted.txt vs.
ref 5 sorted.txt