1 flush

2 operator<<

3 put

4 seekp

5 tellp

6 write

 

1 flush

刷新输出流

2 operator<<

插入运算符

3 put

无格式,插入一个字符

4 seekp

移动输出流指针

5 tellp

返回输出流中指定位置的指针值

6 write

从无格式,插入一字节序列

 

std::cout.write(str, 10);//最大输出10个字符,不包含'\0'

 

 1 #include <iostream>
 2 
 3 void main()
 4 {
 5     char str[] = "123456789abcdefg";
 6 
 7     std::cout.write(str, 10);//最大输出10个字符,不包含'\0'
 8 
 9     system("pause");
10 }

 

相关文章:

  • 2022-12-23
  • 2021-06-16
  • 2021-12-19
  • 2022-02-22
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-16
  • 2022-12-23
相关资源
相似解决方案