文章

1

粉丝

137

获赞

0

访问

6.7k

头像
为什么mle?实在搞不懂
P1850 清华大学2020年机试题
发布于2021年3月4日 00:22
阅读数 6.7k

  1. // n1850.cpp : This file contains the 'main' function. Program execution begins and ends there.
  2. //
  3. #include <iostream>
  4. #include <iomanip>
  5. #include <fstream>
  6. #include <algorithm>
  7. #include <cstdio>
  8. #include <cmath>
  9. #include <cstring>
  10. #include <limits.h>
  11. #include <deque>
  12. #include <vector>
  13. #include <queue>
  14. #include <string>
  15. #include <map>
  16. #include <stack>
  17. #include <set>
  18. #include <unordered_map>
  19. #include <unordered_set>
  20. using namespace std;
  21. int _2darray[1000][1000];
  22. int n, m;
  23. bool row(int r,int&_1st_x,int&_2nd_x, int& _1st_y, int& _2nd_y) {
  24. int _1st = 0, _2nd = 0;
  25. for (int i = 0; i < m; i++) {
  26. if (_2darray[r][i] != 0) {
  27. if (_1st == 0) {
  28. _1st = _2darray[r][i];
  29. _1st_x = r;
  30. _1st_y = i;
  31. }
  32. else
  33. {
  34. _2nd = _2da...
登录查看完整内容


登录后发布评论

暂无评论,来抢沙发