็ตๆ
ๅ้ก | No.8077 ๐ง |
ใฆใผใถใผ |
|
ๆๅบๆฅๆ | 2022-01-23 13:58:34 |
่จ่ช | C++17 (gcc 13.3.0 + boost 1.87.0) |
็ตๆ |
AC
|
ๅฎ่กๆ้ | 2 ms / 2,000 ms |
ใณใผใ้ท | 1,566 bytes |
ใณใณใใคใซๆ้ | 2,299 ms |
ใณใณใใคใซไฝฟ็จใกใขใช | 192,968 KB |
ๆ็ตใธใฃใใธๆฅๆ | 2025-01-27 14:57:48 |
ใธใฃใใธใตใผใใผID ๏ผๅ่ๆ ๅ ฑ๏ผ |
judge2 / judge4 |
๏ผ่ฆใญใฐใคใณ๏ผ
ใใกใคใซใใฟใผใณ | ็ตๆ |
---|---|
sample | AC * 3 |
other | AC * 10 |
ใฝใผในใณใผใ
#include <bits/stdc++.h>#define rep(i, n) for (int i = 0; i < (int)(n); i++)#define rrep(i, n) for (int i = (int)(n - 1); i >= 0; i--)#define all(x) (x).begin(), (x).end()#define sz(x) int(x.size())#define yn(joken) cout<<((joken) ? "Yes" : "No")<<endl#define YN(joken) cout<<((joken) ? "YES" : "NO")<<endlusing namespace std;using ll = long long;using vi = vector<int>;using vl = vector<ll>;using vs = vector<string>;using vc = vector<char>;using vd = vector<double>;using vvi = vector<vector<int>>;using vvl = vector<vector<ll>>;const int INF = 1e9;const ll LINF = 1e18;template <class T>bool chmax(T& a, const T& b) {if (a < b) {a = b;return 1;}return 0;}template <class T>bool chmin(T& a, const T& b) {if (b < a) {a = b;return 1;}return 0;}template <class T>vector<T> make_vec(size_t a) {return vector<T>(a);}template <class T, class... Ts>auto make_vec(size_t a, Ts... ts) {return vector<decltype(make_vec<T>(ts...))>(a, make_vec<T>(ts...));}template <typename T>istream& operator>>(istream& is, vector<T>& v) {for (int i = 0; i < int(v.size()); i++) {is >> v[i];}return is;}template <typename T>ostream& operator<<(ostream& os, const vector<T>& v) {for (int i = 0; i < int(v.size()); i++) {os << v[i];if (i < int(v.size()) - 1) os << ' ';}return os;}int main(){cin.tie(nullptr);ios::sync_with_stdio(false);ll A,B,C,D,K;cin>>A>>B>>C>>D>>K;cout<<(A*B+C-D)%K<<endl;}