练习:敲打代码

部署运行你感兴趣的模型镜像

@冒泡排序

void psort(int a[], int len);

@快速排序

void qsort(int a[], int len);

@选择排序

void ssort(int a[], int len);

@插入排序

void isort(int a[], int len);

@堆排序

void hsort(int a[], int len);

@希尔排序

void xsort(int a[], int len);

@归并排序

void msort(int a[], int len);

@链表基础操作

Node* createList(int len);
Node* createList(int a[], int len);
void destroyList(Node* head);
Node* pushNode(Node* head, int num) ;
Node* insertNode(Node* head, int pos, int num) ;
void deleteNode(Node* head, int pos) ;
Node* deleteNode(Node* head, int num) ;
Node* modifyNode(Node* head, int src, int dst) ;
Node* mergeList(Node* h1, Node* h2) ;
int listCount(Node* head) ;

@二分查找

int biSearch(int a[], int len);

@链表翻转

Node* revertList(Node* head)

@链表中第K个节点

@Node* findKNode(Node* head, int k);

@链表中倒数第K个节点

Node* findKNode(Node* head, int k);

@合并两个排序链表

Node* mergeList(Node* h1, Node* h2);

@复杂链表的复制

Node* cloneList(Node* head);

@链表中环的入口

Node* cirList(Node* head);

@删除链表中重复的节点

Node* delDupNode(Node* head);

@两个链表的第一个公共节点

Node* firstComNode(Node* h1, Node* h2);

@大数相加

std::string addBig(const std::string& num1, const std::string& num2);

@大数相减

std::string subBig(const std::string& num1, const std::string& num2);

@大数相乘

std::string multiBig(const std::string& num1, const std::string& num2);

@求最大公约数

int findGCD(int num1, int num2);

@求最小公倍数

int findLCM(int num1, int num2);

@数值的整数次方

double power(double base, int exp);

@二叉树前序遍历(递归+非递归)

std::vector<int> preOrder(TreeNode* root)

@二叉树中序遍历(递归+非递归)

std::vector<int> midOrder(TreeNode* root)

@二叉树后续遍历(递归+非递归)

std::vector<int> postOrder(TreeNode* root)

@二叉树层序遍历(递归+非递归)

std::vector<int> levelOrder(TreeNode* root)

@已知前序中序(或前序后续,或中序后序)重建二叉树

TreeNode* rebuild(std::vector<int> vec1, std::vector<int> vec2);

@二叉树镜像

TreeNode* mirror(TreeNode* root);

@二叉树的深度

int depth(TreeNode* root);

@二叉树中和为某一数值的路径

std::vector<std::vector<int>> findPath(TreeNode* root, int num);

@中序(或前序,或后序)二叉树的下一个节点

TreeNode* findNext(TreeNode* root)

@判断是否为对称二叉树

bool isMirror(TreeNode* root);

@替换空格为123

std::string replaceSpace(int a[]);

@数组中出现次数不超过一半的数字

int findNum(std::vector<int> nums);

@最小的k个数

std::vector<int> findKNums(std::vector<int> nums, int k);

@单词的个数

int wordsCount(std::string str);

@找出所有的单词

std::vector<std::string> allWords(std::string str);

@翻转单词序列

std::string reverseWords(std::string str);

@5个扑克牌顺子,大小王为0

bool isStraight(std::vector<int>);

@约瑟夫环

int LastRemaining(int n, int m);

@与或非异或

不使用其他变量交换两个整数

@字符串转换为整数

int str2Int(std::string str);

@strcpy实现

char* strcpy(char* des, const char* src)

@strlen实现

int strlen(const char* str);

@strcat实现

char* strcat(char* des, const char* src);

@strcmp实现

int strcmp(const char *s1,const char *s2);

@数组中重复数字

int dupNum(std::vector<int> nums);

@字符流中第一个不重复的数字

int firstNotDup(std::vector<int> nums);

@全排列

std::vector<std::string> permutation(std::string str);

@LCS算法-最长公共子序列

std::string findStr(std::string s1, std::string s2);

@LCS算法-最长公共子串

std::string findStr(std::string s1, std::string s2);

@斐波那契数列(递归+非递归迭代)

int fi(int n);

@判断是否回文串

bool isPalindrome(std::string str);

@求最长回文子串

bool maxPalindrome(std::string str);

@寻找和为定值的两个数

std::vector<int> findNums(std::vector<int> vec)

@hash算法

@括号匹配{}

@波兰式

@逆波兰式

@接雨水问题

@最大直方图矩形面积

@图的遍历-广度优先算法BFS

@图的遍历-深度优先算法DFS

@8皇后问题

@101-200之间的素数个数并打印

@正整数分解质因数

@递归求和

@递归求阶乘n!

您可能感兴趣的与本文相关的镜像

ACE-Step

ACE-Step

音乐合成
ACE-Step

ACE-Step是由中国团队阶跃星辰(StepFun)与ACE Studio联手打造的开源音乐生成模型。 它拥有3.5B参数量,支持快速高质量生成、强可控性和易于拓展的特点。 最厉害的是,它可以生成多种语言的歌曲,包括但不限于中文、英文、日文等19种语言

源码地址: https://pan.quark.cn/s/d1f41682e390 miyoubiAuto 米游社每日米游币自动化Python脚本(务必使用Python3) 8更新:更换cookie的获取地址 注意:禁止在B站、贴吧、或各大论坛大肆传播! 作者已退游,项目不维护了。 如果有能力的可以pr修复。 小引一波 推荐关注几个非常可爱有趣的女孩! 欢迎B站搜索: @嘉然今天吃什么 @向晚大魔王 @乃琳Queen @贝拉kira 第三方库 食用方法 下载源码 在Global.py中设置米游社Cookie 运行myb.py 本地第一次运行时会自动生产一个文件储存cookie,请勿删除 当前仅支持单个账号! 获取Cookie方法 浏览器无痕模式打开 http://user.mihoyo.com/ ,登录账号 按,打开,找到并点击 按刷新页面,按下图复制 Cookie: How to get mys cookie 当触发时,可尝试按关闭,然后再次刷新页面,最后复制 Cookie。 也可以使用另一种方法: 复制代码 浏览器无痕模式打开 http://user.mihoyo.com/ ,登录账号 按,打开,找到并点击 控制台粘贴代码并运行,获得类似的输出信息 部分即为所需复制的 Cookie,点击确定复制 部署方法--腾讯云函数版(推荐! ) 下载项目源码和压缩包 进入项目文件夹打开命令行执行以下命令 xxxxxxx为通过上面方式或取得米游社cookie 一定要用双引号包裹!! 例如: png 复制返回内容(包括括号) 例如: QQ截图20210505031552.png 登录腾讯云函数官网 选择函数服务-新建-自定义创建 函数名称随意-地区随意-运行环境Python3....
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值