Wrong Answer

foo.cc: In function 'int getMinSwaps(std::vector<int>&)':
foo.cc:12:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   12 |     for (int i = 0; i < sortedNums.size(); i++)mp[sortedNums[i]] = i ;//记录下标索引
      |                     ~~^~~~~~~~~~~~~~~~~~~
foo.cc:14:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   14 |     for (int i = 0; i < nums.size();i++)
      |                     ~~^~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Wrong Answer Read 5, expect 7. 2ms 256.0 KiB
#2 Wrong Answer Read 12, expect 17. 1ms 256.0 KiB
#3 Wrong Answer Read 65, expect 96. 1ms 256.0 KiB
#4 Wrong Answer Read 125, expect 194. 1ms 256.0 KiB
#5 Wrong Answer Read 625, expect 984. 1ms 384.0 KiB
#6 Wrong Answer Read 1249, expect 1966. 1ms 384.0 KiB
#7 Wrong Answer Read 1851, expect 2938. 2ms 512.0 KiB
#8 Wrong Answer Read 2495, expect 3913. 5ms 512.0 KiB
#9 Wrong Answer Read 3072, expect 4874. 3ms 512.0 KiB
#10 Wrong Answer Read 4854, expect 7672. 8ms 640.0 KiB

信息

递交者
类型
递交
题目
P1220 4 排序中的交换次数
语言
C++
递交时间
2022-08-21 21:03:08
评测时间
2022-08-21 21:03:08
评测机
分数
0
总耗时
29ms
峰值内存
640.0 KiB