![](https://img-blog.csdnimg.cn/20201014180756757.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
C++
视觉未入门
视觉未入门
展开
-
程序设计与算法(一)C语言程序设计--第三周测试
001:奇偶数判断#define _CRT_SECURE_NO_WARNINGS#include <iostream> #include <cstdio>using namespace std;int main(){ int n; cin >> n; if (n % 2) cout << "odd" << end...原创 2019-07-20 00:28:15 · 362 阅读 · 0 评论 -
程序设计与算法(三)测验题
魔兽世界之一:备战#include<iostream>using namespace std;#pragma warning(disable:4996)class CHeadQuarter;class CWarrior {private: int No; int KindNo; CHeadQuarter* p;public: static const cha...原创 2019-09-14 10:31:01 · 478 阅读 · 0 评论 -
程序设计与算法(二)测验汇总(2019夏季)
003:全排列#include <iostream>#include<algorithm>#include<cstring>#pragma warning(disable:4996)using namespace std;char str[10];void permutation(char* done,char* left,int index)...原创 2019-08-02 10:25:50 · 146 阅读 · 0 评论 -
程序设计与算法(三)测验题
013:魔兽世界之一:备战#include <iostream>#pragma warning(disable:4996)using namespace std;class Dragon { int number; int strength; int attack;public: Dragon(int n) :strength(n), number(0) {}...原创 2019-08-06 12:03:33 · 422 阅读 · 0 评论 -
程序设计与算法(一)第13周测验(2019夏季
001:冷血格斗场#include <iostream>#include<map>#include<cmath>#include<algorithm>#pragma warning(disable:4996)using namespace std;typedef int id;typedef int attack;typedef...原创 2019-08-01 12:44:43 · 166 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(一)第12周测验(2019夏季)
003:Set#include <iostream>#include<set>#include<cstring>#pragma warning(disable:4996)using namespace std;typedef multiset<int>::iterator MultIt;void add(multiset<in...原创 2019-07-31 21:49:21 · 407 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(一)第6周测验(2019夏季)
001:Pell数列#include <iostream>#include<cstdio>#include<cstring>#include<cmath>#pragma warning(disable:4996)using namespace std;unsigned int pell[1000010];int a[100];i...原创 2019-07-26 20:58:09 · 245 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(一)第5周测验(2019夏季)
003:年龄与疾病#include <iostream>#include <cstdio>#include<iomanip>#define _CRT_SECURE_NO_WARNINGS#pragma warning(disable:4996)using namespace std;int main(){ //freopen("C:\\Us...原创 2019-07-26 16:53:15 · 311 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(一)第11周测验(2019夏季)
003:Aggressive cows#include<iostream>#include<cstdlib>#pragma warning(disable:4996)using namespace std;const int NUM = 100000;int x[NUM];int Mycompare(const void* e1, const void* ...原创 2019-07-31 15:38:43 · 320 阅读 · 0 评论 -
程序设计与算法(三)第3周测验(2019夏季)
001:返回什么才好呢#include <iostream>using namespace std;class A {public: int val; A(int // Your Code Here n=123) { val = n; } A(A& a) { val = a.val; } A& GetObj() { ret...原创 2019-08-03 23:22:01 · 1163 阅读 · 1 评论 -
程序设计与算法(一)第11周测验(2019夏季)
001:派#include <iostream>#include <iomanip>#include<cstring>#pragma warning(disable:4996)using namespace std;const double EPS = 1.0E-5;const double PI = 3.141592653589793;co...原创 2019-07-30 23:08:13 · 187 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(二)第1周测验(2019夏季)
001:特殊密码锁#define _CRT_SECURE_NO_WARNINGS#include <iostream> #include <cstdio>#include<memory>#include<string>#include<cstring>using namespace std;int GetBit(int...原创 2019-07-21 22:36:15 · 215 阅读 · 0 评论 -
002:简单的整数划分问题
002:简单的整数划分问题等价于放苹果#include <iostream>#pragma warning(disable:4996)using namespace std;int f(int m,int n) { if (m < n) return f(m, m); if (m == 0) return 1; if (n == 0) retur...原创 2019-08-02 20:08:49 · 187 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(一)第10周测验(2019夏季)
001:成绩排序#include <iostream>#include<cstring>using namespace std;#pragma warning(disable:4996)struct Student { char name[100]; int score;};const int NUM = 20;Student stu[NUM];v...原创 2019-07-30 17:06:36 · 346 阅读 · 0 评论 -
程序设计实习MOOC / 程序设计与算法(一)第4周测验(2019夏季)
005:雇佣兵#define _CRT_SECURE_NO_WARNINGS#include <iostream> #include <cstdio>using namespace std;int main(){ int M, N, X, n,nsume; cin >> M >> N >> X; while (X) ...原创 2019-07-20 20:44:51 · 558 阅读 · 0 评论 -
魔兽世界之二:装备
#include<iostream>#pragma warning(disable:4996)using namespace std;class CHeadQuarter;class CWarrior { int No; int KindNo; CHeadQuarter* pHeadQuarter;public: static int strength[5];...原创 2019-09-14 20:21:19 · 602 阅读 · 0 评论