跳到正文

Ghostcoder

1427106

flag【S 1=】【绿+200+】|| 能蒸吗? || 每一粒星光,都曾在黑暗中淬炼。

这是 2026年10月21日 存档的第 1 版,不是当前版本。查看当前版本

资料、奖项与版本

资料

编号
1427106
抓取

版本

  1. v5当前
  2. v4
  3. v3
  4. v2
更早的 1 个版本
  1. v1
Honey reaped from the blade, embers hidden beneath the snow.\text{Honey~reaped~from~the~blade,~embers~hidden~beneath~the~snow.}
工具

小熊猫C++

Jetbrains mono 字体

窗口虚化工具

C++
#include<bits/stdc++.h>
#define int long long
using namespace std;
const int N=;

int read(){
	int x=0,f=1;char ch=getchar();
	while(ch<'0'||ch>'9'){if(ch=='-')f=-1;ch=getchar();}
	while(ch>='0'&&ch<='9'){x=x*10+(ch^48);ch=getchar();}
	return x*f;
}
void print(int x){
	if(x<0){putchar('-');x=-x;}
	if(x>9)print(x/10);
	putchar(x%10+'0');
}
signed main(){
//	ios::sync_with_stdio(0);
//	cin.tie(0);
	
	return 0;
}
位运算(?

位运算常用技巧:

  1. 取出 xx 的第 ii 位:
    C++
    y=(x>>(i-1))&1;
  2. 将 xx 的第 ii 位取反:
    C++
    x^=(1<<(i-1));
  3. 将 xx 的第 ii 位变成 11:
    C++
     x|=(1<<(i-1));
  4. 将 xx 的第 ii 位变成 00:
    C++
    x&=(~(1<<(i-1)));
  5. 将 xx 最靠右的 11 去掉:
    C++
     x=x&(x-1);
  6. 取出 xx 最靠右的 11:
    C++
    y=x&(-x);
  7. 判断是否有两个连续的 11:
    C++
    if(x&(x<<1))cout<<"YES";
  8. 枚举子集:
    C++
    for(int x=sta;x;x=((x-1)&sta))cout<<x;