목록비트마스크 (1)
레야몬
[C++] 11723번 집합 - 집합
#include #include using namespace std; int M, x; //수행해야 하는 연산의 수, 입력받는 숫자 int set[21]; //비트마스크 string cal; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); cin >> M; for (int i=0; i> cal; if (!cal.compare("all")) { for (int j=1; j> x; if (!cal.compare("add")) //값 추가하기 set[x]=1; else if (!cal.compare("check")) //값이 들어있는지 확인 cout [C++] set container 정리 및 사용법 안녕하세요. Blo..
알고리즘/백준
2022. 8. 30. 20:40