結果
| 問題 | No.481 1から10 |
| コンテスト | |
| ユーザー |
vjudge1
|
| 提出日時 | 2026-02-11 01:31:30 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 3,292 bytes |
| 記録 | |
| コンパイル時間 | 2,658 ms |
| コンパイル使用メモリ | 225,960 KB |
| 実行使用メモリ | 7,844 KB |
| 最終ジャッジ日時 | 2026-02-11 01:31:37 |
| 合計ジャッジ時間 | 4,123 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 8 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using vi = vector<int>;
using vc = vector<char>;
using vs = vector<string>;
using vll = vector<ll>;
#define int long long
#define f first
#define s second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
#define foo(i, a, b) for (int i = (a); i < (b); ++i)
#define rfoo(i, a, b) for (int i = (a); i >= (b); --i)
#define input(v) \
for (auto &x : v) \
cin >> x
#define print(v) \
for (auto x : v) \
cout << x << " "; \
cout << '\n'
#define yes cout << "YES" << std::endl;
#define no cout << "NO" << std::endl;
#define nl cout << "\n";
const int MOD = 1e9 + 7;
const ll INF = 1e18;
ll gcd(ll a, ll b) { return b ? gcd(b, a % b) : a; }
ll power(ll a, ll b)
{
ll res = 1;
while (b)
{
if (b & 1)
res *= a;
a *= a;
b >>= 1;
}
return res;
}
ll modexp(ll a, ll b, ll mod = MOD)
{
ll res = 1;
a %= mod;
while (b)
{
if (b & 1)
res = (res * a) % mod;
a = (a * a) % mod;
b >>= 1;
}
return res;
}
ll modmul(ll a, ll b, ll mod = MOD)
{
return ((a % mod) * (b % mod)) % mod;
}
bool isprime(int n)
{
if (n < 2)
return false;
for (int i = 2; i * i <= n; ++i)
if (n % i == 0)
return false;
return true;
}
void sieve(int n, vector<bool> &isPrime)
{
isPrime.assign(n + 1, true);
isPrime[0] = isPrime[1] = false;
for (int i = 2; i * i <= n; ++i)
if (isPrime[i])
for (int j = i * i; j <= n; j += i)
isPrime[j] = false;
}
int getbit(ll n, int b) { return (n >> b) & 1; }
ll setbit(ll n, int b) { return n | (1LL << b); }
ll resetbit(ll n, int b) { return n & ~(1LL << b); }
ll togglebit(ll n, int b) { return n ^ (1LL << b); }
bool ispoftwo(ll n) { return n > 0 && !(n & (n - 1)); }
int countSetBits(ll n) { return __builtin_popcountll(n); }
int digitCount(ll n, int base = 10)
{
return n ? (int)(log(n) / log(base)) + 1 : 1;
}
vi factors(int n)
{
vi res;
for (int i = 1; i * i <= n; i++)
{
if (n % i == 0)
{
res.pb(i);
if (i != n / i)
res.pb(n / i);
}
}
sort(all(res));
return res;
}
#define lb(v, x) (lower_bound(all(v), x) - (v).begin())
#define ub(v, x) (upper_bound(all(v), x) - (v).begin())
#define count_occ(v, x) (ub(v, x) - lb(v, x))
#define fastio \
ios::sync_with_stdio(false); \
cin.tie(nullptr); \
cout.tie(nullptr)
signed main()
{
fastio;
int t = 1;
// cin >> t;
while (t--)
{
vi v(9);
input(v);
ll sum=0;
ll su = 0;
foo(i,0,10) {
su+=i+1;
}
foo(i,0,9) {
sum += v[i];
}
cout<<su-sum;
}
}
// string a,b,c;
// cin>>a;
// cin>>b;
// cin>>c;
// swap(a[0],a[2]); swap(a[1],a[2]);
// swap(b[1],b[2]);
// reverse(c.begin(),c.end());
// cout<<a[0] << " " << a[1] << " "<<a[2];
// nl
// cout<<b[0] << " " << b[1]<< " "<< b[2];
// nl
// cout<<c[0] << " " << c[1] << " " << c[2];
vjudge1