More like a warm-up question, I want to know who can win my variation:
Accordingly, we read from 1 and write to 2
Who will win by the amount of code?
Answer 1, authority 100%
I don’t know about the amount of code, but in terms of speed, perhaps this option is faster:
Answer 2, authority 40%
exec('sort 1 | uniq > 2');