Give implementation for write-file for people that didn't do the challenge.