Since the name writeDicToFile might make us confuse, changed the name to
be more clear what it does