結果

問題 No.478 一般門松列列
ユーザー ふーらくたる
提出日時 2017-01-27 22:51:57
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 847 bytes
コンパイル時間 563 ms
コンパイル使用メモリ 67,552 KB
実行使用メモリ 6,824 KB
最終ジャッジ日時 2024-12-23 16:38:31
合計ジャッジ時間 5,292 ms
ジャッジサーバーID
(参考情報)
judge4 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other WA * 34
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <utility>
#include <cstdio>
#include <queue>
#include <stack>
#include <algorithm>
#include <numeric>
#include <vector>
#include <set>
#include <map>
#include <string>
#include <cstring>
using namespace std;

#define ALL(a) (a).begin(), (a).end()

using ll = long long;
using P = pair<int, int>;

struct State {
    int v, cost;

    State(int v, int cost): v(v), cost(cost) {}

    // 昇順
    bool operator<(const State& s) const {
        return cost < s.cost;
    }
    // 降順
    bool operator>(const State& s) const {
        return cost > s.cost;
    }
};

void dump_vector(vector<int> vec) {
    for (int i = 0; i < vec.size(); i++) {
        cout << vec[i] << (i < vec.size() - 1 ? " " : "\n");
    }
}

int main() {
    ll n, k;
    cin >> n >> k;

    cout << n / (k + 1) + 1 << endl;

    return 0;
}
0