Update examples for new I/O api.