結果

問題 No.2545 Divide by 3
ユーザー 沙耶花沙耶花
提出日時 2023-11-24 22:41:06
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 759 bytes
コンパイル時間 4,571 ms
コンパイル使用メモリ 261,100 KB
実行使用メモリ 6,676 KB
最終ジャッジ日時 2023-11-24 22:41:12
合計ジャッジ時間 5,122 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,676 KB
testcase_01 AC 2 ms
6,676 KB
testcase_02 AC 2 ms
6,676 KB
testcase_03 AC 2 ms
6,676 KB
testcase_04 AC 2 ms
6,676 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <stdio.h>
#include <atcoder/all>
#include <bits/stdc++.h>
using namespace std;
using namespace atcoder;
using mint = modint998244353;
#define rep(i,n) for (int i = 0; i < (n); ++i)
#define Inf32 1000000001
#define Inf64 4000000000000000001

int main(){
	
	long long D = 1<<30;
	long long t = (D)/3;
	/*
	long long nn;
	cin>>nn;
	rep(i,nn){
		int n = 1000000000-i;
		if(n/3 != ((n+1)*t)/D){
			cout<<i<<endl;
			cout<<n/3<<endl;
			cout<<((n+1)*t)/D<<endl;
		}
	}
	*/
	cout<<78<<endl;
	cout<<"plus 1 1 2"<<endl;
	cout<<"plus 4 1 4"<<endl;
	rep(i,30){
		if((t>>i)&1){
			cout<<"plus 5 4 5"<<endl;
		}
		cout<<"plus 4 4 4"<<endl;
	}
	cout<<"plus 3 5 3"<<endl;
	rep(i,30){
		cout<<"div 3 3"<<endl;
	}
	//cout<<__builtin_popcountll(t)<<endl;
	return 0;
}
0