会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
yh2924
博客园
首页
新随笔
联系
管理
订阅
上一页
1
2
3
4
5
下一页
2020年3月21日
C++之bitset
摘要: 1 #include <iostream> 2 #include <bitset> 3 #include <string> 4 5 using namespace std; 6 //bitset类型处理二进制 7 int main() 8 { 9 //bitset类型的变量a <>内的参数表示的是长
阅读全文
posted @ 2020-03-21 08:03 萌萌~
阅读(176)
评论(0)
推荐(0)
2020年3月19日
C++之bitset
摘要: 1 #include <iostream> 2 #include <bitset> 3 #include <string> 4 5 using namespace std; 6 //bitset类型处理二进制 7 int main() 8 { 9 //bitset类型的变量a <>内的参数表示的是长
阅读全文
posted @ 2020-03-19 12:19 萌萌~
阅读(153)
评论(0)
推荐(0)
C++之迭代器
摘要: 1 vector<int> v(10,8); 2 vector<int>::iterator iter=v.begin(); //begin返回一个迭代器 3 4 //实质上是一个指针 5 *iter=9; 6 iter++; 7 *iter=10; 8 vector<int>::iterator
阅读全文
posted @ 2020-03-19 11:21 萌萌~
阅读(126)
评论(0)
推荐(0)
C++之vector
摘要: 1 #include <iostream> 2 #include <vector> 3 4 using namespace std; 5 6 int main(){ 7 //vector容器 是一个动态数组 8 //<>里面表示的是模板参数 vector为类模板 9 vector<int> ivec
阅读全文
posted @ 2020-03-19 10:41 萌萌~
阅读(116)
评论(0)
推荐(0)
2020年3月18日
C++之string
摘要: 1 #include <iostream> 2 #include<string> 3 4 using namespace std; 27 int main(){ 28 29 //C++标准库中的string类型 30 string name("张三"); 31 cout<<name<<endl; 3
阅读全文
posted @ 2020-03-18 10:29 萌萌~
阅读(174)
评论(0)
推荐(0)
2020年3月17日
C++之变量
摘要: 1 #include <iostream> 2 3 using namespace std; 4 5 int i; 6 7 int main() 8 { 9 void Bianliang(); 10 Bianliang(); 11 return 0; 12 } 13 14 #if(1) 15 voi
阅读全文
posted @ 2020-03-17 08:17 萌萌~
阅读(231)
评论(0)
推荐(0)
2020年3月16日
数据结构之单链表基本操作 C语言
摘要: 1 #include <stdio.h> 2 #include <stdlib.h> 3 #define OK 0 4 #define ERROR -1 5 6 // 7 typedef int Status; 8 typedef int ElemType; 9 10 /* 11 单链表的存储结构:
阅读全文
posted @ 2020-03-16 08:37 萌萌~
阅读(399)
评论(0)
推荐(0)
2020年3月15日
C语言之内存分配
摘要: malloc函数: //void *malloc(unsigned int size) int *p; p=(int*)malloc(sizeof(int))//分配一个连续的内存空间,通过类型转换才能存入其他类型的变量。 函数的功能是分配一块长度为size字节的连续空间,由于不知道分配出来的空间是
阅读全文
posted @ 2020-03-15 10:26 萌萌~
阅读(253)
评论(0)
推荐(0)
2020年3月14日
数据结构之时间复杂度 C语言
摘要: 算法的时间复杂度:用O()表示,执行次数=时间,随着输入规模n增大,T(n)增长最慢的算法为最优算法。如何计算时间复杂度:用常数1取代运行时间中的所有加法常数在修改后的运行次数函数中,只保留最高阶项如果最高阶项存在且不是1,则去除与这个项相乘的常数得到的最后结果就是O阶 int i,n=100,su
阅读全文
posted @ 2020-03-14 15:25 萌萌~
阅读(1656)
评论(0)
推荐(0)
2020年3月13日
C语言之结构体
摘要: 1 #include <stdio.h> 2 #include <stdlib.h> 3 //用指向函数的指针做函数参数 4 #if(0) 5 int main() 6 { 7 struct Student{ 8 long int num; 9 char name[20]; 10 char sex;
阅读全文
posted @ 2020-03-13 15:35 萌萌~
阅读(222)
评论(0)
推荐(0)
上一页
1
2
3
4
5
下一页
公告