Function write (21/32)

Function write