当前位置: 首页 > news >正文

自己建网站花钱吗注册100万的公司一年缴纳多少税

自己建网站花钱吗,注册100万的公司一年缴纳多少税,wordpress开发小程序,和田地网站seo目录 1.string 介绍 2. 初始化 3.输入 4.修改string对象 5.substr截取字符串 6.插入 7.删除 8.替换 9.查找 10.其它操作 1.string 介绍 string是一种字符串类#xff0c;可以不通过定义字符数组来存储字符串#xff0c;方便对字符串的一系列操作#xff0c;使用时…目录 1.string 介绍 2. 初始化 3.输入 4.修改string对象 5.substr截取字符串 6.插入 7.删除 8.替换 9.查找 10.其它操作 1.string 介绍 string是一种字符串类可以不通过定义字符数组来存储字符串方便对字符串的一系列操作使用时要加上头文件 #includestring 2. 初始化 1常量字符串构造 string str(Hello); 2拷贝构造 string str(Hello); string s(str); 3拷贝构造的第二种方式 string str(Hello); string s str; 4string(size_type n,char c) 创建一个包含 n 个c的 string 对象 string str(5,a);coutstr; //输出aaaaa (5)部分拷贝构造 string str(hello); string str2(str,2,3); //下标2开始的3个字符coutstr2; //输出llo 3.输入 string的输入方式不止一种每一种都有细微差别 1cin 键盘输入会跳过开头的空白直到遇到下一个空白为止 string str;cinstr; //输出abcd efg coutstr; //输出abcd 2getline(cin,str) 读取一整行 string str;getline(cin,str); //输出 abcd efg coutstr; //输出 abcd efg 4.修改string对象 1通过拼接两个对象 string s1(hello); string s2(world); string strs1s2;coutstr; //输出helloworld 2通过append()在末尾添加 string str(hello); str.append(world);coutstr; //输出helloworld 3通过push_back()在末尾添加一个字符 string str(hello); str.push_back(a);coutstr; //输出helloa 5.substr截取字符串 1substr(pos,n) 返回从pos下标开始的n个字符pos默认为下标0n默认为s.size()-pos string str(hello); string str2str.substr(2,3);coutstr2; //输出llo 2substr(pos) string str(hello); string str2str.substr(2);coutstr2; //输出llo 6.插入 (1)迭代器位置插入单个字符 string str(hello); str.insert(str.begin(),a);coutstr; //输出ahello 2迭代器位置插入多个字符 string str(hello); str.insert(str.begin(),3,a); //插入3个acoutstr; //输出aaahello 3在下标index前插入n个字符 string str(hello); str.insert(2,3,a);coutstr; //输出heaaallo 4下标index前插入一个常量字符串或者string对象 string str(hello); string s(abab); str.insert(2,s); //下标2处插入scoutstr; //输出heababllo 5下标index前插入str中的从某一下标开始的n个字符 string str(hello); string s(abab); str.insert(2,s,0,2); //下标2处插入s下标0开始的两个字符 coutstr; //输出heabllo 7.删除 1erase删除全部 string str(hello);str.erase(); //清空 coutstr; //输出空 2erase(pos,n) 删除下标pos开始的n个字符 string str(hello);str.erase(2,2); //下标2开始的两个字符 coutstr; //输出heo 3erase迭代器 string str(hello);str.erase(str.begin()); //删除开头一个字符 coutstr; //输出ello 8.替换 (1)replaceposns从下标pos开始删除n个字符删除后在下标pos处插入s string str(hello); string s(aaa);str.replace(2,2,s); //从下标2开始删除2个字符删除后在下标2处插入scoutstr; //输出 heaaao (2)replaceposnsab从下标pos开始删除n个字符删除后在下标pos处插入s中下标a开始的b个字符 string str(hello); string s(aaa);str.replace(2,2,s,2,1); 从下标2开始删除2个字符删除后在下标2处插入s的下标2开始的1个字符 coutstr; //输出 heao 9.查找 1finds返回s字符第一次出现的下标 string str(hello);coutstr.find(ll); //输出2 2finds,pos从字符串的 pos 位置开始查找s返回s字符第一次出现的下标 string str(hello);coutstr.find(l,3); //输出3 3rfind 与find)类似不过是从后往前找 string str(hello);coutstr.rfind(l); //输出3 4string.find_first_of() 在字符串中从指定位置开始向后默认为索引 0 处查找参数中任何一个字符首次出现的位置 string str(hello world people);coutstr.find_first_of(woooll); //输出2 5find_last_of() 方法在字符串中查找参数中任何一个字符最后一次出现的位置即从后往前找第一个 string str(hello world people);coutstr.find_last_of(woooll); //输出16 6string.find_first_not_of() 在字符串中查找第一个不包含在参数中的字符 string str(hello world people);coutstr.find_first_not_of(hwoooll); //输出1 7find_last_not_of() 在字符串中查找最后一个不包含在参数中的字符 string str(hello world people);coutstr.find_last_not_of(hwoooll); //输出17 10.其它操作 1empty判空 若字符串为空则返回真否则返回假 string str(hello world people);coutstr.empty(); //输出0 2swap 函数交换两个字符串 string s1(hello); string s2(world); s1.swap(s2);couts1endl; //输出world couts2endl; //输出hello
http://www.hkea.cn/news/14274464/

相关文章:

  • 长沙手机网站制作江苏常州建设银行网站
  • 南城网站建设公司报价青峰网站建设
  • wordpress关站实验室网站建设意义
  • 企业建站设计网站建设招标信息
  • 金华建设公司网站上不了国外网站 怎么做贸易
  • 可以做笔试面试题的网站做防水保温怎么建网站
  • 网站如何收录快简述企业网站如何推广
  • 免费网站从哪里申请自己做的网站网站搜索
  • 溧阳网站开发网站富文本的内容怎么做
  • 湖南网站营销seo方案分销系统商城
  • zencart 网站搬家wordpress4.7主题制作
  • 建设部网站官网 造价鉴定三合一商城网站
  • 财务公司网站源码安卓市场官方版
  • 如何做网站 优帮云企业网站开发费是固定资产吗
  • 安徽中颐建设投资有限公司网站虚拟主机管理
  • 合水网站建设wordpress页面父级
  • 网站开发后期做什么王烨萍
  • 明光网站数据库连接wordpress
  • html网站开发需要什么软件温州市瓯海建设局网站
  • 沧州省建设厅网站电商 网站 建设
  • h5 小米网站模板福建建设执业资格注册管理中心网站
  • 聊城集团网站建设价格西安电商平台网站
  • 简单网站建设流程图教育与培训网站建设
  • 怎样利用网站做引流如何建设公司的网站
  • mvc做的游戏网站代码seo 网站排名
  • 网站怎么做图片动态图片不显示不出来中山网站建设文化策划
  • 3d演示中国空间站建造历程网页设计尺寸的分辨率
  • 网站备案ftp密码模板网站建站哪家好
  • 做配电柜在哪个网站发布信息贵阳网站推广
  • 网站建设方案 规划为什么建设的网站有时候访问慢