with open("CSV", 'w') as f: f.write('\n'.join([",".join(map(str,[a,b,c,d,e])) for (a, b), ((c, d), e) in sorted(myDict.items())]))
Explanation -
sorted(myDict.items()) will sort the dictionary based on keys.
for (a, b), ((c, d), e) in sorted(myDict.items()) will unpack your values.
",".join(map(str,[a,b,c,d,e])) joins the unpacked values ββwith a comma.
[",".join(map(str,[a,b,c,d,e])) for (a, b), ((c, d), e) in sorted(myDict.items())] - This is an understanding of the list of the above values, separated by commas.
'\n'.join([",".join(map(str,[a,b,c,d,e])) for (a, b), ((c, d), e) in sorted(myDict.items())] join the above list with new characters.