#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @File  : 字符串IO操作.py
# @Author: lch
# @Date  : 2019/1/31
# @Desc  :
import io

s = io.StringIO("hello\n")
print(s.read(2))
print(s.read())
c29c71f65aae70dbffb30a80c59bbdba3147a20d
<mask token>

<mask token>
print(s.read(2))
print(s.read())

<mask token>
s = io.StringIO('hello\n')
print(s.read(2))
print(s.read())

import io
s = io.StringIO('hello\n')
print(s.read(2))
print(s.read())

#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @File  : 字符串IO操作.py
# @Author: lch
# @Date  : 2019/1/31
# @Desc  :
import io

s = io.StringIO("hello\n")
print(s.read(2))
print(s.read())