- 博客(22)
- 收藏
- 关注
原创 C++算法(6)桶排序
#include<iostream> #include<vector> #include<algorithm> //** 计数排序,不考虑数据特征,无脑排序,用的不多 */ using namespace std; void BucketSort(vector<int> &, int, int...
2019-11-25 10:04:56 141
原创 Leetcode (2)
/******************************************************************** 给出两个 非空 的链表用来表示两个非负的整数。其中,它们各自的位数是按照 逆序 的方式存储的,并且它们的每个节点只能存储 一位 数字。 如果,我们将这两个数相加起来,则会返回一个新的链表来表示它们的和。 您可以假设除了数字...
2019-11-22 16:40:47 97
原创 C++算法(5) 堆排序
#include<iostream> #include<vector> #include<algorithm> using namespace std; //int partion(vector<int>&, int, int); void StackSort(vector<int&g...
2019-11-22 16:38:15 94
原创 C++算法(4) 快排
1、 #include<iostream> #include<vector> #include<algorithm> using namespace std; int clipe(vector<int>&, int left, int right); int main() { ...
2019-11-21 16:56:28 140
原创 C++算法(1) 排序 和 查找
sort排序 #include<iostream> #include<string> #include<algorithm> using namespace std; void BubbleSort(int list[], int n); int main() { int list[5...
2019-11-19 16:49:49 181 1
原创 Leetcode (30) C语言实现:给定一个只包括 '(',')','{','}','[',']' 的字符串
bool isValid(char * s){ char temp1; int i = 0; int TSIZE = strlen(s); typedef struct { char data[TSIZE]; int top; int bottom; }stack; //** 创建 */...
2019-11-05 13:56:05 1571
原创 C语言基础学习(20)结构链表制作
//** 结构链表制作 **/ #include<stdio.h> #include<string.h> #include<stdlib.h> char * s_gets(char *, int); struct film * InputIfor(struct film*); void PutIfor(struct ...
2019-11-02 15:18:28 88
原创 C语言基础学习(19)传递结构的地址,结构体,但没有结构的指针
指针的问题```c#include<stdio.h>#include<string.h>#define NLEN 30char* s_get(char *, int );struct namect{ char fname[NLEN]; char lname[NLEN]; int letters;};void getinfor(...
2019-11-01 15:38:56 144
原创 C语言基础学习(16) s_get
s_gets函数的应用:#include<stdio.h>#include<string.h>char* s_get(char *, int );int main(){ char st1[2] ="s"; s_get(st1, 4); //puts(st1); printf("%s\n", st1); return 0...
2019-11-01 15:12:25 685
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人