求最大公约数和最小公倍数 摘要:#include<iostream>#include<math.h>using namespace std;int mods(int a,int b){ while(b!=0){ int te…… 文章列表 2019年03月17日 5 点赞 0 评论 1050 浏览 评分:9.9
树状数组+差分(树状数组区间更新与查询)模板,自用 摘要:自用模板,原理网上一大堆,不过建议自己跟着题目敲几遍,有部分所谓题解代码是错的。<树状数组区间更新与查询>#include<bits/stdc++.h> using namespace std; …… 文章列表 2019年03月16日 2 点赞 0 评论 987 浏览 评分:0.0
练习过程中的心得 摘要:1.在类型转换这个陷阱上,一定要注意隐藏的自动转换,很容易出错,如 float = int 这类型,最后printf的时候,会为0.0000…… 文章列表 2019年03月14日 1 点赞 0 评论 615 浏览 评分:0.0
差分数组,树状数组,自用模板 摘要:放点自用模板...自用的<差分数组>#include<bits/stdc++.h> using namespace std; const int maxn=100005; int orign[m…… 文章列表 2019年03月14日 3 点赞 0 评论 698 浏览 评分:0.0
qsort快排函数cmp用法总结 摘要:函数参数:qsort(s,n,sizeof(s[0]),cmp);int数组:int cmp(const void *a, const void *b){ return(*(int *)a…… 文章列表 2019年03月12日 0 点赞 0 评论 1032 浏览 评分:8.2
c++中string类的简单介绍 摘要:#include "iostream" #include "string" using namespace std; /*@author:浅滩 *family:c++中string类的简单介绍…… 文章列表 2019年03月06日 0 点赞 0 评论 976 浏览 评分:0.0
实用不常用的字符串字符函数记录 摘要:统一头文件<ctype.h>字符串:strncpy(p, p1, n) 复制指定长度字符串 strcat(p, p1) 附加字符串 strncat(p, p1, n) 附加指定长度字符串 strcas…… 文章列表 2019年03月06日 0 点赞 0 评论 540 浏览 评分:0.0
向世界级C语言大师致敬。 摘要:个人原创!!!!#include int main() { printf(&((char)NULL)["www.如鹏网\0.com"]+((*"ru"-*"peng")<<SEEK_CUR…… 文章列表 2019年03月06日 1 点赞 0 评论 681 浏览 评分:0.0
史上最牛,访问数组元素,至少几十种访问数组元素的方式!! 摘要:个人原创,源代码:#include<stdio.h> int main(){ int a[5]={1,2,3,4,5}; printf("a[0]=%d\n",a[0]); printf("a…… 文章列表 2019年03月06日 3 点赞 0 评论 1306 浏览 评分:0.0
json格式的字符串转C语言结构体(二) 摘要:由于C语言中没有提供反射机制,所以实现起来,还是很有趣的有兴趣的可以私聊我交流群:599151072…… 文章列表 2019年03月06日 0 点赞 0 评论 1581 浏览 评分:0.0