⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 prog.cpp

📁 C++ primer 4th edition 部分习题解答 前十章
💻 CPP
字号:
#include<iostream>
#include<string>
#include<vector>
#include<bitset>
#include<math.h>
using namespace std;

int main()
{
	long int num=pow(2,1)+pow(2,2)+pow(2,3)+pow(2,5)+pow(2,8)+pow(2,13)+pow(2,21);
	bitset <32> first(num);
	cout<<first<<endl;
	
	bitset <32> second;
	second.set(1);
	second.set(2);
	second.set(3);
	second.set(5);
	second.set(8);
	second.set(13);
	second.set(21);
	cout<<second<<endl;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -