Update example_write.c

Uodate example.