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

买网站送域名有哪些免费做网站

买网站送域名,有哪些免费做网站,网页版qq怎么登录,长春市城建网站具体代码 /*自定义迭代器的实现 */ #include <iostream> using namespace std; class num {int val; //具体的数字int length; //数字的位数void calculate_length(){if(val/100){ //这个数字只有1位length1;return;}int x10; //这里就是不断重复除直…

具体代码

/*自定义迭代器的实现
*/
#include <iostream>
using namespace std;
class num
{int val;    //具体的数字int length; //数字的位数void calculate_length(){if(val/10==0){      //这个数字只有1位length=1;return;}int x=10;           //这里就是不断重复除直到为0,从而得出数字的具体位数int pow=0;int tempNum=val;while(tempNum!=0){tempNum/=10;pow++;}length=pow;}
public:num(int tempNum){ //以下是一些基本的函数,用于设置值val=tempNum;calculate_length();}void set(int tempNum){val = tempNum;calculate_length();}int get(){return val;}//以下是迭代器的部分class iterator{int pos;    //数字的下标num* obj;   //如果要在迭代器里面访问num的内容,必须要这个public:/*迭代器,要重载*,++,--*/iterator(num* ptr,int n){pos = n;obj = ptr;}iterator(){//空构造器pos = 0;obj = nullptr;}//操作符void operator++(){  //注意,这种没有参数的++重载的是前置的++   ++itpos++;}void operator++(int i){  //这种有任意int参数的重载的是后缀++  it++pos++;}void operator--(){pos--;}void operator--(int i){  pos--;}int operator*()const{//13324 取第二位10位:  (13324%100)/10//num  去除第n位     (num % 10^(n))/ 10^(n-1)if(pos>=obj->length) return -1;if(pos==0)return obj->val%10;int o=10;int pow=0;while(pow<(pos-1)){// cout<<pow<<" "<<pos<<endl;o*=10;pow++;}return (obj->val%(o*10))/(o);}bool operator!=(const iterator& it){return it.pos!=pos;}bool operator==(const iterator& it){return it.pos==pos;}};//获取迭代器,常见的比如begin,end;iterator begin(){return iterator(this,0);}iterator end(){return iterator(this,length);}
};
int main()
{num a(2354862);for(auto it=a.begin();it!=a.end();it++){cout<<*it<<" ";}cout<<endl;return 0;
}

参考资料

https://blog.csdn.net/dyyzlzc/article/details/103336232

http://www.yayakq.cn/news/134503/

相关文章:

  • 罗湖商城网站设计推荐网站优化排名首页
  • 网站的建设与推广帮做论文网站吗
  • 人物设计网站wordpress主题 淘客
  • 凡科互动游戏修改器一流的镇江网站优化
  • 四川手机网站怎样自创广告网站
  • 做网站哪家公司专业南宁小程序开发网站建设公司
  • 易企网站建设公司霸屏网站开发
  • 网站一级页面二级页面怎么做哪个网站可以做彩经专家
  • 平面设计素材网站哪个好服务器 wordpress 邮件
  • 网站用什么语言开发网站开发ceil(5.5)
  • 穿衣搭配的网站如何做三亚百度推广公司
  • 哪些网站建设公司浅议我国旅游景点网站的建设
  • 河北明迈特的网站在哪里做的做超市海报的网站
  • 深圳微商城网站设计电话wordpress wifri
  • 网站开发投标文件服务承诺部分app软件开发团队
  • 网站排名突然掉没了网站建设w亿玛酷1专注
  • 网站开发nodejs近期时事新闻10条
  • 网站的ftp帐号移动开发是干什么的
  • 建设网站好处小程序模板购买
  • 南昌网站建设冲浪者科技seo提高关键词
  • 南昌做网站的公司哪里好老师让做网站怎么做
  • 如何做自己的电影网站网站建设分类方案
  • 组建网站开发团队wordpress树结构插件
  • 网站建设对客户的优势android studio官网
  • 建设公司网站的细节全国小微企业名录
  • 清溪网站仿做青岛建筑网
  • 网站静态页面下载工具工程交易网
  • 四川华泰建设集团网站wordpress黑糖
  • c 做网站简单吗用微信怎么做企业网站
  • 虚拟空间网站ftp如何差异化同步大品牌网站建设