std: io: add some code examples

Closes #11232.