Submission #17758979
Source Code Expand
Copy
#include <bits/stdc++.h>
using namespace std;
typedef signed long long ll;
#undef _P
#define _P(...) (void)printf(__VA_ARGS__)
#define FOR(x,to) for(x=0;x<(to);x++)
#define FORR(x,arr) for(auto& x:arr)
#define FORR2(x,y,arr) for(auto& [x,y]:arr)
#define ITR(x,c) for(__typeof(c.begin()) x=c.begin();x!=c.end();x++)
#define ALL(a) (a.begin()),(a.end())
#define ZERO(a) memset(a,0,sizeof(a))
#define MINUS(a) memset(a,0xff,sizeof(a))
//-------------------------------------------------------
ll A,B,C;
const ll mo=998244353;
void solve() {
int i,j,k,l,r,x,y; string s;
cin>>A>>B>>C;
A=A*(A+1)/2%mo;
B=B*(B+1)/2%mo;
C=C*(C+1)/2%mo;
ll ret=A*B%mo*C%mo;
cout<<ret<<endl;
}
int main(int argc,char** argv){
string s;int i;
if(argc==1) ios::sync_with_stdio(false), cin.tie(0);
FOR(i,argc-1) s+=argv[i+1],s+='\n'; FOR(i,s.size()) ungetc(s[s.size()-1-i],stdin);
cout.tie(0); solve(); return 0;
}
Submission Info
Submission Time |
|
Task |
A - Simple Math |
User |
kmjp |
Language |
C++ (GCC 9.2.1) |
Score |
300 |
Code Size |
940 Byte |
Status |
AC |
Exec Time |
6 ms |
Memory |
3588 KB |
Compile Error
./Main.cpp: In function ‘void solve()’:
./Main.cpp:20:6: warning: unused variable ‘i’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp:20:8: warning: unused variable ‘j’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp:20:10: warning: unused variable ‘k’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp:20:12: warning: unused variable ‘l’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp:20:14: warning: unused variable ‘r’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp:20:16: warning: unused variable ‘x’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp:20:18: warning: unused variable ‘y’ [-Wunused-variable]
20 | int i,j,k,l,r,x,y; string s;
| ^
./Main.cpp: In function ‘int main(int, char**)’:
./Main.cpp:7:28: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
7 | #define FOR(x,to) for(x=0;x<(to);x++)
| ^
./Main.cpp:34:38: note: in expansion of macro ‘FOR’
34 | FOR(i,argc-1) s+=argv[i+1],s+='\n'; FOR(i,s.size()) ungetc(s[s.size()-1-i],stdin);
| ^~~
Judge Result
Set Name |
Sample |
All |
Score / Max Score |
0 / 0 |
300 / 300 |
Status |
|
|
Set Name |
Test Cases |
Sample |
example_00, example_01 |
All |
example_00, example_01, max_random_00, max_random_01, max_random_02, small_00, small_01, small_02 |
Case Name |
Status |
Exec Time |
Memory |
example_00 |
AC |
6 ms |
3588 KB |
example_01 |
AC |
1 ms |
3548 KB |
max_random_00 |
AC |
2 ms |
3460 KB |
max_random_01 |
AC |
1 ms |
3588 KB |
max_random_02 |
AC |
4 ms |
3524 KB |
small_00 |
AC |
2 ms |
3548 KB |
small_01 |
AC |
2 ms |
3548 KB |
small_02 |
AC |
2 ms |
3552 KB |