Fixed the bug in naive algorithm, there was an error in the blocking pair check. Also added some newline to the output