码迷,mamicode.com
首页 >  
搜索关键字:typedef struct    ( 24378个结果
一个完整的使用成员函数指针的例子
Screen.h#ifndef SCREEN_H#define SCREEN_H#include class Screen {public: typedef std::string::size_type pos; // Action is a type that can point to...
分类:其他好文   时间:2014-06-04 20:59:09    阅读次数:350
【HDOJ】1180 诡异的楼梯
bfs+优先队列。wa了N次,才发现可以停留等待楼梯变换方向。 1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 7 #define MAXNUM 55 8 9 typedef struct node...
分类:其他好文   时间:2014-06-03 13:26:06    阅读次数:274
linux中时间函数
linux下常用时间类型有四种: time_t 、 struct tm、 struct timeval 、 struct timespec1、time_t 时间函数 time_t 类型在time.h中定义: #ifndef __TIME__T #define __TIME_...
分类:系统相关   时间:2014-05-30 23:18:32    阅读次数:467
linux 内核 中链表list
这个结构从list.h 移到了types.h, 可见内核对循环链表的重视include/linux/types.h中定义struct list_head { struct list_head *next, *prev;};include/linux/list.h 中的宏初始化 一个叫name的链表节...
分类:系统相关   时间:2014-05-30 23:10:13    阅读次数:412
Max Points on a Line
Givennpoints on a 2D plane, find the maximum number of points that lie on the same straight line./** * Definition for a point. * struct Point { * ...
分类:其他好文   时间:2014-05-30 16:27:19    阅读次数:238
Populating Next Right Pointers in Each Node
Given a binary tree struct TreeLinkNode { TreeLinkNode *left; TreeLinkNode *right; TreeLinkNode *next; }Populate each next pointe...
分类:其他好文   时间:2014-05-30 15:21:20    阅读次数:181
treap模版代码
treap模版暂存。以后修改整理。#include#include#include #includeusing namespace std;struct Node{ Node *ch[2];//左右子树 int r;//优先级。数值越大,优先级越高 int v;//值 int...
分类:其他好文   时间:2014-05-30 01:45:16    阅读次数:250
生化武器2--bfs
1 #include //bfs; 2 #include 3 #include 4 #include 5 using namespace std; 6 struct data 7 { 8 int x,y,t; 9 }now,pos; 10 int n,m,t,dis[...
分类:其他好文   时间:2014-05-30 01:26:49    阅读次数:242
Go数据结构之Queue
Queue 简单而实用的数据结构,FIFO,通过循环数组避免队列出现“似乎满了”的现象。package Queueimport "errors"const ( defaultQueueSize=10)var queueSize inttype MyQueue struct{ front...
分类:其他好文   时间:2014-05-30 00:48:43    阅读次数:284
剑指OFFER之链表中倒数第k个节点(九度OJ1517)
题目描述:输入一个链表,输出该链表中倒数第k个结点。(hint: 请务必使用链表。)输入:输入可能包含多个测试样例,输入以EOF结束。对于每个测试案例,输入的第一行为两个整数n和k(0#include typedef struct node{ int number; struct nod...
分类:其他好文   时间:2014-05-30 00:29:13    阅读次数:325
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!