#include #include #include using namespace std; const double pi = acos(-1.0);const int maxn = 500005; struct complex{ double r,i; complex(double r = 0...
分类:
其他好文 时间:
2014-08-21 21:03:39
阅读次数:
341
1.链表1.1链表的存储表示//链表的存储表示typedef int ElemType;typedef struct LNode{ ElemType data; struct LNode *next;}LNode, *LinkList;1.2基本操作创建链表:/* * 创建链表。 * 形参num为链...
分类:
其他好文 时间:
2014-08-21 21:01:14
阅读次数:
221
switch语句一般可以用if重写,但是if语句不一定能用switch重写 public enum StausType { /// /// 友情链接 /// linkInfo = 1 ...
分类:
其他好文 时间:
2014-08-21 19:05:34
阅读次数:
323
一、队的概念 队列也是一种表,但是是一种受限的表,只允许从一端插入,另一端山粗的表。 二、队列的数组实现 #define QMAXSIZE 100typedef int Position;typedef int QElement;typedef struct queue{ QElement Els[...
分类:
其他好文 时间:
2014-08-21 18:53:24
阅读次数:
186
#include
#include
#include
using namespace std;
#define maxx 100050
struct node
{
int a,b,id;
}g[maxx];
int root[maxx];
int id[maxx];
int len;
void output(int x)
{
if(x==-1)return;
outp...
分类:
其他好文 时间:
2014-08-21 17:12:34
阅读次数:
174
package mainimport "fmt"type PersonInfo struct { ID string Name string Address string}func main() { var personDB map[string]Person...
分类:
其他好文 时间:
2014-08-21 14:51:34
阅读次数:
195
public class Enum2 { public Dictionary GetEnumItems() { Dictionary dicResult = new Dictionary(); T obj ...
分类:
其他好文 时间:
2014-08-21 14:46:04
阅读次数:
164
/**
* 功能:嵌套友元
* 时间:2014年8月21日07:21:29
* 作者:cutter_point
*/
#include
#include //为了初始化时使用memset()
#include
using namespace std;
const int sz=20;
struct Holder
{
private:
int a[sz]; //一个整形...
分类:
编程语言 时间:
2014-08-21 09:53:23
阅读次数:
238
static voidseedrand (){ struct timeval tv; gettimeofday (&tv, NULL); sbrand (tv.tv_sec ^ tv.tv_usec ^ getpid ());}上述是bash中生成随机数的代码,处理是非常的简单,秒 (tv.tv_s...
分类:
其他好文 时间:
2014-08-20 22:34:52
阅读次数:
206
怪物AI执行//-----------------------------------------------主动攻击------------------------------------------------------初始状态attack_style Enum攻击方式 ...
分类:
其他好文 时间:
2014-08-20 22:21:22
阅读次数:
275