結果

問題 No.1415 100の倍数かつ正整数(1)
ユーザー ninoinuininoinui
提出日時 2021-12-26 09:41:25
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
CE  
(最新)
AC  
(最初)
実行時間 -
コード長 3,670 bytes
コンパイル時間 10,574 ms
コンパイル使用メモリ 653,648 KB
最終ジャッジ日時 2024-04-27 04:00:29
合計ジャッジ時間 10,952 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
コンパイルエラー時のメッセージ・ソースコードは、提出者また管理者しか表示できないようにしております。(リジャッジ後のコンパイルエラーは公開されます)
ただし、clay言語の場合は開発者のデバッグのため、公開されます。

コンパイルメッセージ
In file included from /boost_git/boost/geometry/strategies/geographic/distance.hpp:38,
                 from /boost_git/boost/geometry/strategies/strategies.hpp:94,
                 from /boost_git/boost/geometry/geometry.hpp:57,
                 from /boost_git/boost/geometry.hpp:17,
                 from main.cpp:5:
/boost_git/boost/geometry/geometries/point_xy.hpp: In member function 'void boost::geometry::model::d2::point_xy<CoordinateType, CoordinateSystem>::x(const CoordinateType&)':
/boost_git/boost/geometry/geometries/point_xy.hpp:69:27: error: type/value mismatch at argument 1 in template parameter list for 'template<class _Key, class _Compare, class _Alloc> class std::set'
   69 |     { this->template set<0>(v); }
      |                           ^
/boost_git/boost/geometry/geometries/point_xy.hpp:69:27: note:   expected a type, got '0'
/boost_git/boost/geometry/geometries/point_xy.hpp:69:27: error: template argument 2 is invalid
/boost_git/boost/geometry/geometries/point_xy.hpp:69:27: error: template argument 3 is invalid
/boost_git/boost/geometry/geometries/point_xy.hpp: In member function 'void boost::geometry::model::d2::point_xy<CoordinateType, CoordinateSystem>::y(const CoordinateType&)':
/boost_git/boost/geometry/geometries/point_xy.hpp:73:27: error: type/value mismatch at argument 1 in template parameter list for 'template<class _Key, class _Compare, class _Alloc> class std::set'
   73 |     { this->template set<1>(v); }
      |                           ^
/boost_git/boost/geometry/geometries/point_xy.hpp:73:27: note:   expected a type, got '1'
/boost_git/boost/geometry/geometries/point_xy.hpp:73:27: error: template argument 2 is invalid
/boost_git/boost/geometry/geometries/point_xy.hpp:73:27: error: template argument 3 is invalid
In file included from /boost_git/boost/geometry/geometries/geometries.hpp:29,
                 from /boost_git/boost/geometry/algorithms/detail/closest_points/linear_or_areal_to_areal.hpp:20,
                 from /boost

ソースコード

diff #

#ifndef _DEBUG
#define _DEBUG
#include __FILE__

#include <boost/geometry.hpp>
#include <boost/multiprecision/cpp_dec_float.hpp>
#include <boost/multiprecision/cpp_int.hpp>
namespace bg = boost::geometry;
namespace mp = boost::multiprecision;

typedef mp::cpp_int bint;
typedef mp::cpp_dec_float_50 bdec;
typedef bg::model::point<bdec, 2, bg::cs::cartesian> point;
typedef bg::model::linestring<point> line;
typedef bg::model::box<point> box;
typedef bg::model::polygon<point> polygon;

int main() {
    bint N;
    cin >> N;

    if (N < 100) return cout << 0 << '\n', 0;
    cout << N / 100 << '\n';
}

#else
// #undef _DEBUG
#include <bits/stdc++.h>
using namespace std;

template <typename T, typename T2>
bool cmin(T& a, const T2& b) {
    return a > b ? a = b, true : false;
}

template <typename T, typename T2>
bool cmax(T& a, const T2& b) {
    return a < b ? a = b, true : false;
}

__attribute__((constructor)) void ios_setup() {
    ios_base::sync_with_stdio(false);
    cin.tie(nullptr);
}

template <typename T>
ostream& operator<<(ostream& os, const vector<T>& vec);

template <typename T>
ostream& operator<<(ostream& os, const vector<vector<T> >& vec);

template <typename T>
ostream& operator<<(ostream& os, const vector<vector<vector<T> > >& vec);

template <typename T, typename U>
ostream& operator<<(ostream& os, const pair<T, U>& p) {
    return os << "(" << p.first << ", " << p.second << ")";
}

template <typename A, typename B, typename C>
ostream& operator<<(ostream& os, const tuple<A, B, C>& t) {
    const auto& [a, b, c] = t;
    return os << "(" << a << ", " << b << ", " << c << ")";
}

template <typename A, typename B, typename C, typename D>
ostream& operator<<(ostream& os, const tuple<A, B, C, D>& t) {
    const auto& [a, b, c, d] = t;
    return os << "(" << a << ", " << b << ", " << c << ", " << d << ")";
}

template <typename T>
ostream& operator<<(ostream& os, priority_queue<T> pq) {
    os << "{";
    while (!pq.empty()) os << pq.top() << (pq.size() > 1 ? " " : ""), pq.pop();
    return os << "}";
}

#define FOREACH(it, a) for (auto it = (a).begin(); it != (a).end(); it++)

template <typename T>
ostream& operator<<(ostream& os, const set<T>& se) {
    os << "{";
    FOREACH (it, se) { os << (it == se.begin() ? "" : " ") << *it; }
    return os << "}";
}

template <typename T>
ostream& operator<<(ostream& os, const multiset<T>& ms) {
    os << "{";
    FOREACH (it, ms) { os << (it == ms.begin() ? "" : " ") << *it; }
    return os << "}";
}

template <typename T, typename U>
ostream& operator<<(ostream& os, const map<T, U>& ma) {
    os << "{";
    FOREACH (it, ma) { os << (it == ma.begin() ? "" : " ") << *it; }
    return os << "}";
}

template <typename T>
ostream& operator<<(ostream& os, const vector<T>& vec) {
    os << "{";
    FOREACH (it, vec) { os << (it == vec.begin() ? "" : " ") << *it; }
    return os << "}";
}

template <typename T>
ostream& operator<<(ostream& os, const vector<vector<T> >& vec) {
    os << "{\n";
    FOREACH (it, vec) { os << (it == vec.begin() ? " " : "\n ") << *it; }
    return os << "\n}";
}

template <typename T>
ostream& operator<<(ostream& os, const vector<vector<vector<T> > >& vec) {
    os << "{\n";
    FOREACH (it, vec) {
        os << (it == vec.begin() ? "" : "\n") << "(" << it - vec.begin() << ") " << *it;
    }
    return os << "\n}";
}

void dump() {}
template <typename Head, typename... Tail>
void dump(const Head& head, const Tail&... tail) {
    cout << head << (sizeof...(tail) ? ", " : "\n"), dump(tail...);
}

#ifdef _DEBUG
#define DUMP(...) cout << "[" << (#__VA_ARGS__) << "] ", dump(__VA_ARGS__)
#else
#define DUMP(...) (void)0
#endif

#endif
0