首页 软件开发 代码片段 c/c++ ( Page 5 )

c/c++ 378

#C/C++
C++排序(合并排序)

//合并排序 #include <iostream> #include <iomanip> using namespace std; void sort(i…

2015-08-12 526

#C/C++
C++快速排序(以中间元素为元点)

#include <iostream> using namespace std; void Grial(int a[],int x,int y) { if(x>=…

2015-08-12 704

#C/C++
C++单链表对环的操作

#include <iostream> using namespace std; template<typename _Ty> class Node { p…

2015-08-12 228

#C/C++
Hash线性探测法C++实现

#include <iostream> #include <iomanip> #define DefaultSize 10 using namespace …

2015-08-12 931

#C/C++
C++排序(小堆排序)

#include<iostream> #include<string> using namespace std; template<class Typ…

2015-08-12 1,024

#C/C++
C++排序(快速排序)

#include <iostream> #define _SZ 10 using namespace std; template<typename _Ty>…

2015-08-12 726

#C/C++
C++字典的线性表实现

#include <iostream> #include <assert.h> using namespace std; struct SchoolNo {…

2015-08-12 842

#C/C++
获取IOS设备类型名

- (NSString*)deviceString { // 需要#import "sys/utsname.h" struct utsname systemIn…

2015-08-11 191

#C/C++
iOS 获取当前Wifi的SSID

首先添加框架:SystemConfiguration.framework #import <SystemConfiguration/CaptiveNetwork.h> …

2015-07-29 480

#C/C++
KMP字符串查找算法

KMP算法的重点是寻找next数组,程序如下: #include <iostream> #include <string> #include <vec…

2015-07-27 829

#C/C++
C语言调用mysql的存储过程

下面假设有一张sc表,保存学生选课记录,有课程号,学号,平时分,卷面分,总分。 建立数据库表过程: create table class( cno varchar(8) not n…

2015-07-22 565

#C/C++
C字符串处理函数

1)字符串操作  strcpy(p, p1) 复制字符串  strncpy(p, p1, n) 复制指定长度字符串  strcat(p, p1) 附加…

2015-07-17 1,020
1 3 4 5 6 7 32