A.txt - O(N^2)
B.txt - O(N Log N)