ICode9

精准搜索请尝试: 精确搜索
  • 深信服笔试 3.242020-03-24 21:56:19

    题目比较基础 1.水桶叠放 输入:水桶数目  和  水桶容量  输出:从下向上加水,求溢出了多少水? 思路:最大连续子序列的思路有点像。 1 int main(){ 2 while(cin >> N >> X){ 3 int tmpNum, tmpAdd; 4 stack<int> tmpStack; 5 while(N--){ 6

  • PAT 2014 秋2019-08-21 23:02:48

    A 1084 Broken Keyboard   注意大小写即可。 1 #include <cstdio> 2 #include <iostream> 3 #include <algorithm> 4 #include <string> 5 6 using namespace std; 7 8 int main() 9 {10 string inStr, outStr;11 cin >> inStr >> o

  • PAT 2012 冬2019-08-16 09:57:36

    A Shortest Distance   题意相当于一个环,找出两点间从不同方向得到的距离中的最小值。 1 #include <cstdio> 2 #include <iostream> 3 #include <algorithm> 4 #include <vector> 5 6 using namespace std; 7 vector<int> disVec; 8 int main() 9 {10 int N, tmpDis

  • PAT A1001-A10042019-08-12 23:52:56

    题集通道:https://pintia.cn/problem-sets/994805342720868352/problems/type/7 A1001 :  A+B Format (20 point(s))   解这道题的关键是题目所给的条件: - 10e6 <= a,b <= 10e6,所以a+b最多为7位数。   代码如下: 1 #include <cstdio> 2 #include <iostream> 3 #include <cstdl

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有