08 2011 档案

摘要:1 #include <stdio.h> 2 #include <string.h> 3 #include <stdlib.h> 4 #include <ctype.h> 5 #include <stack> 6 usingnamespace std; 7 8 stack<float> OperandStack; 9 stack<char> OperatorStack; 10 11 char priority[]={'(', ')', '', '+' 阅读全文
posted @ 2011-08-18 23:01 IT屁民 阅读(766) 评论(0) 推荐(1)
摘要:1、struct ,union两种结构的特点,所占内存特点(比如内存对齐)。2、enum的用法3、typedef 联合 struct的用法………… 阅读全文
posted @ 2011-08-17 21:14 IT屁民 阅读(254) 评论(0) 推荐(0)
摘要:1 #include <stdio.h> 2 #include <string.h> 3 char haab[18][10]={ 4 "pop", "no", "zip", "zotz", "tzec", "xul", "yoxkin", "mol", "chen", 5 "yax", "zac", "ceh", "mac& 阅读全文
posted @ 2011-08-06 20:19 IT屁民 阅读(299) 评论(0) 推荐(0)
摘要:1 #include <stdio.h> 2 #include <stdlib.h> 3 4 char d[100][51]; 5 struct node 6 { 7 int p; 8 int r; 9 };10 11 node s[100];12 13 int cmp( constvoid*a, constvoid*b)14 {15 return ((node*)a)->r - ((node*)b)->r;16 }17 int DNAsort(char a[],int n)18 {19 int count =0;20 for(int i =0; i < 阅读全文
posted @ 2011-08-06 17:56 IT屁民 阅读(175) 评论(0) 推荐(0)
摘要:#include<iostream>using namespace std;int main(int argc, char* argv[]){ int p,e,i,d; int index=0; while(cin>>p>>e>>i>>d) { if(p==-1) break; int n=(5544*p+14421*e+1288*i-d)%(21252); if(n<=0) n+=21252; cout<<"Case "<<++index<<": the nex 阅读全文
posted @ 2011-08-05 22:08 IT屁民 阅读(163) 评论(0) 推荐(0)
摘要:#include <stdio.h>#define PI 3.1415926int main(){ int n, i = 0, year; double x, y, area; scanf("%d", &n); while (i < n) { scanf("%lf %lf", &x, &y); area = 0.5 * PI * (x*x+y*y); year = area/50; printf("Property %d: This ... 阅读全文
posted @ 2011-08-05 20:45 IT屁民 阅读(156) 评论(0) 推荐(0)