/ Vijos /

记录详情

Accepted

/in/foo.cc: In function 'std::vector<int> add(std::vector<int>&, std::vector<int>&)':
/in/foo.cc:16:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for (int i = 0; i < a.size() || i < b.size(); i++)
                  ~~^~~~~~~~~~
/in/foo.cc:16:36: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for (int i = 0; i < a.size() || i < b.size(); i++)
                                  ~~^~~~~~~~~~
/in/foo.cc:18:9: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (i < a.size()) t += a[i];
       ~~^~~~~~~~~~
/in/foo.cc:19:9: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (i < b.size()) t += b[i];
       ~~^~~~~~~~~~
/in/foo.cc: In function 'std::vector<int> sub(std::vector<int>&, std::vector<int>&)':
/in/foo.cc:33:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for (int i = 0; i < a.size(); i++)
                  ~~^~~~~~~~~~
/in/foo.cc:36:9: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (i < b.size()) t -= b[i]; // 有b就减
       ~~^~~~~~~~~~
/in/foo.cc: In function 'std::vector<int> mul(std::vector<int>&, std::vector<int>&)':
/in/foo.cc:79:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for (int i = 0; i < A.size(); i++)
                  ~~^~~~~~~~~~
/in/foo.cc:80:21: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   for (int j = 0; j < B.size(); j++)
                   ~~^~~~~~~~~~
/in/foo.cc:83:27: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  for (int i = 0, t = 0; i < C.size() || t; i++)
                         ~~^~~~~~~~~~
/in/foo.cc:86:9: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (i >= C.size()) C.push_back(t % 10);
       ~~^~~~~~~~~~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:136:6: warning: unused variable 'lenC' [-Wunused-variable]
  int lenC = 0;
      ^~~~
# 状态 耗时 内存占用
#1 Accepted 1ms 376.0 KiB
#2 Accepted 1ms 376.0 KiB
#3 Accepted 15ms 412.0 KiB
#4 Accepted 172ms 664.0 KiB

信息

递交者
类型
递交
题目
P1040 高精度乘法
语言
C++
递交时间
2022-01-12 17:24:39
评测时间
2022-01-12 17:24:39
评测机
分数
100
总耗时
191ms
峰值内存
664.0 KiB