Submission #13834591


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 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;
double B;

void solve() {
	int i,j,k,l,r,x,y; string s;
	
	cin>>A>>B;
	A*=B*100;
	cout<<A/100<<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 C - Multiplication 3
User kmjp
Language C++ (GCC 9.2.1)
Score 0
Code Size 816 Byte
Status WA
Exec Time 6 ms
Memory 3780 KB

Compile Error

./Main.cpp: In function ‘void solve()’:
./Main.cpp:19:6: warning: unused variable ‘i’ [-Wunused-variable]
   19 |  int i,j,k,l,r,x,y; string s;
      |      ^
./Main.cpp:19:8: warning: unused variable ‘j’ [-Wunused-variable]
   19 |  int i,j,k,l,r,x,y; string s;
      |        ^
./Main.cpp:19:10: warning: unused variable ‘k’ [-Wunused-variable]
   19 |  int i,j,k,l,r,x,y; string s;
      |          ^
./Main.cpp:19:12: warning: unused variable ‘l’ [-Wunused-variable]
   19 |  int i,j,k,l,r,x,y; string s;
      |            ^
./Main.cpp:19:14: warning: unused variable ‘r’ [-Wunused-variable]
   19 |  int i,j,k,l,r,x,y; string s;
      |              ^
./Main.cpp:19:16: warning: unused variable ‘x’ [-Wunused-variable]
   19 |  int i,j,k,l,r,x,y; string s;
      |                ^
./Main.cpp:19:18: warning: unused variable ‘y’ [-Wunused-variable]
   19 |  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:31:38: note: in expansion of macro ‘FOR’
   31 |  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 0 / 300
Status
AC × 3
AC × 15
WA × 5
Set Name Test Cases
Sample sample_01.txt, sample_02.txt, sample_03.txt
All hand_01.txt, hand_02.txt, hand_03.txt, random_01.txt, random_02.txt, random_03.txt, random_11.txt, random_12.txt, random_13.txt, random_21.txt, random_22.txt, random_23.txt, random_31.txt, random_32.txt, random_33.txt, sample_01.txt, sample_02.txt, sample_03.txt, zero_01.txt, zero_02.txt
Case Name Status Exec Time Memory
hand_01.txt WA 2 ms 3632 KB
hand_02.txt WA 2 ms 3696 KB
hand_03.txt WA 1 ms 3708 KB
random_01.txt AC 2 ms 3640 KB
random_02.txt AC 3 ms 3680 KB
random_03.txt AC 2 ms 3712 KB
random_11.txt AC 2 ms 3696 KB
random_12.txt WA 2 ms 3780 KB
random_13.txt WA 2 ms 3676 KB
random_21.txt AC 2 ms 3640 KB
random_22.txt AC 2 ms 3700 KB
random_23.txt AC 6 ms 3676 KB
random_31.txt AC 2 ms 3692 KB
random_32.txt AC 2 ms 3728 KB
random_33.txt AC 2 ms 3776 KB
sample_01.txt AC 2 ms 3672 KB
sample_02.txt AC 2 ms 3620 KB
sample_03.txt AC 2 ms 3768 KB
zero_01.txt AC 3 ms 3692 KB
zero_02.txt AC 2 ms 3768 KB