疯狂的指针
疯狂的指针
全部文章
分类
C/C++(10)
c语言(1)
git(1)
Git教程(2)
IO模型(1)
leetcode(18)
LeetCode题解(3)
Linux(7)
PLC(3)
Python(7)
socket(1)
中国(2)
其他(1)
冒泡排序(1)
动态规划(6)
回溯法(1)
回溯法基础(3)
快速排序(1)
接口(2)
数据结构(5)
未归档(187)
树状数组(1)
浙大PAT-A题目集(30)
浙大PAT-B题目集(23)
深入学习C++(14)
生物(1)
程序员升职记(10)
笔试(2)
经济学人(6)
英语学习(1)
读书笔记(3)
谷歌(1)
归档
标签
去牛客网
登录
/
注册
Vincent's Blog
全部文章
(共355篇)
【C++】输出格式
#include<iostream> #include<stdlib.h> using namespace std; int main() { cout<<"please enter a number"<<endl; ...
2016-04-25
0
673
【动态规划】凑硬币
算法 推荐阅读:从动态规划新手到专家 上面是在网上看到的一篇好文章,里面有一个凑硬币的问题 如果我们有面值为1元、3元和5元的硬币若干枚,如何用最少的硬币凑够11元? (表面上这道题可以用贪心算法,但贪心算法无法保证可以求出解,比如1元换成2元的时候) 首先我们思考一个问题,如何用最少的硬币凑够i元...
2016-04-22
0
894
【排序】堆排序
程序代码: #include<iostream> #define MAX 1000 using namespace std; void Sift(int* r,int size,int i); void swap(int *num,int i,int j); int main() { ...
2016-04-22
0
472
【排序】简单选择排序
程序代码: //简单选择排序 #include<iostream> using namespace std; void SelectSort(int* r,int n); int main() { int num[8]; for(int i=0;i<8;i++)...
2016-04-22
0
472
【排序】希尔排序
程序代码: //Shell排序 #include<iostream> using namespace std; void ShellSort(int* r,int n); int main() { int num[11]; for(int i=1;i<11;i+...
2016-04-22
0
439
【排序】直接插入排序
程序代码: //直接插入排序 #include<iostream> using namespace std; void InsertSort(int* r,int n); int main() { int num89]; for(int i=0;i<8;i++) ...
2016-04-22
0
435
快速排序的实现
输入9个数字,采用快速排序法从小到大排序输出。 输入样例: 49 38 65 97 76 13 27 49 20 输出样例: 13 20 27 38 49 49 65 76 97 程序代码: #include<iostream> using namespace std; vo...
快速排序
2016-04-21
0
473
【c++】寻找等差数列
在给定的区间范围内找出所有素数能构成的最大的等差数列(即等差数列包含的素数个数最多)。 输入样例: 1 10 输出样例: 3 5 7 程序代码: #include<iostream> #include<cstdio> #include<cmath> #...
2016-04-12
0
728
【c++】蛇形矩阵
题目说明 蛇形矩阵是由1开始的自然数依次排列成的一个矩阵上三角形。 样例输入: 5 样例输出: 1 3 6 10 15 2 5 9 14 4 8 13 7 12 11 程序代码1: #include<iostream> using namespace std; #defin...
2016-04-11
0
505
【c++】挑7
输出7有关数字的个数,包括7的倍数,还有包含7的数字(如17,27,37…70,71,72,73…)的个数. 输入:一个正整数N。(N不大于30000) 输出:不大于N的与7有关的数字个数,例如输入20,与7有关的数字包括7,14,17. 样例输入: 20 样例输出: 3 程序代码1:...
2016-04-11
0
707
首页
上一页
23
24
25
26
27
28
29
30
31
32
下一页
末页