码迷,mamicode.com
首页 >  
搜索关键字:struct stat    ( 35365个结果)
0长度数组的使用
0长度的数组在ISO C和C++的规格说明书中是不允许的,但是GCC的C99支持的这种用法。GCC对0长度数组的文档参考:“Arrays of Length Zero”如下代码片段,哪个更简洁更灵活,看一眼就知道了:#include #include typedef struct tagArray....
分类:其他好文   时间:2014-07-07 08:25:56    阅读次数:235
MFC第一节-windows程序内部运行机制
一、窗口设计窗口类时: 1 typedef struct _WNDCLASS{ 2 UINT style; //如水平、垂直变化是否重绘,禁用Close,检测双击 3 WNDPROC lpfnWndProc;//窗口过程函数句柄 4 int cbClsExtra;//类附加内存 5 int cbWn...
分类:Windows程序   时间:2014-07-07 00:25:20    阅读次数:332
linux下USB设备驱动
本文以USB鼠标讲解USB设备驱动。驱动程序中调用usb_register(struct usb_driver *)函数时,先判断USB总线驱动程序是否支持usb_driver里定义的id_table,若支持,调用usb_driver的probe函数。所以首先要定义并初始化usb_driver结构体...
分类:系统相关   时间:2014-07-06 23:38:42    阅读次数:339
外接圆模板
double dis(Point a){ return a.x*a.x+a.y*a.y;}struct Circle Circumcircle(){ Circle tmp; double a,b,c,c1,c2; double xa,ya,xb,yb,xc,yc; a ...
分类:其他好文   时间:2014-07-06 17:39:21    阅读次数:153
Leetcode Valid Number
Validate if a given string is numeric.Some examples:"0"=>true" 0.1 "=>true"abc"=>false"1 a"=>false"2e10"=>trueNote:It is intended for the problem stat...
分类:其他好文   时间:2014-07-05 17:20:00    阅读次数:176
构建有向图邻接表
建立一个有向图的邻接表,首先要构思好它的邻接表里面包含哪些结构数据,然后根据哪些数据来建立相应的结构体。但也要注意数据的输入。#include #include #define MAX_SIZE 10typedef struct ArcNode //弧节点结构体{ ...
分类:其他好文   时间:2014-07-05 11:14:30    阅读次数:177
boost中自动确定数据类型(BOOST_TYPEOF和BOOST_AUTO)的使用
#include #include #include #include BOOST_TYPEOF_INCREMENT_REGISTRATION_GROUP() //为了注册新的数据类型 using namespace std; namespace ex{ //定义新的数据类型 struct demo_class { int a,b; }; BOOST_TYPEOF_REG...
分类:其他好文   时间:2014-07-04 06:53:55    阅读次数:323
转:Object-Runtime的基本数据类型
ClassObjective-C是支持反射的,先来了解一下其如何表达一个类。在Objective-C的Runtime中有个类型是Class(只在Runtime环境中使用),用来表示Objective-C中的类,其定义为:typedef struct objc_class *Class;可以看出,其实...
分类:其他好文   时间:2014-07-03 21:38:17    阅读次数:277
POJ1054 The Troublesome Frog [dp]
艰难的写上一篇,小学期太累了,,,很难坚持刷 #include #include #include #include #include #include using namespace std; int m,n; int num; struct Grid { int x,y; }grid[5555]; int cmp(const void* a,const void* b) { ...
分类:其他好文   时间:2014-07-03 18:39:34    阅读次数:267
VS2012关于hash_map的使用简略
VS关于hash_map使用的一些常用构造方法汇总,包括基本类型和结构体,相信够一般模仿使用: # include #include #include struct order { char orderNO[20]; char name[10]; int NO; char type; }; typedef order Order; struct cmp{ enum {...
分类:其他好文   时间:2014-07-03 15:39:22    阅读次数:254
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!