@with_open_mode('wb+')
@with_sizes('medium')
def modify_seek_forward_blockwise(f, source):
 f.seek(0)
 for i in xrange(0, len(source), 2000):
  f.write(source[i:(i + 1000)])
  f.seek((i + 2000))

@ with_open_mode ( 'wb+' ) @ with_sizes ( 'medium' ) def modify_seek_forward_blockwise ( f , source ) : f . seek ( 0 ) for i in xrange ( 0 , len ( source ) , 2000 ) : f . write ( source [ i : ( i + 1000 ) ] ) f . seek ( ( i + 2000 ) )
alternate write & seek 1000 units .