11 2011 档案

摘要:1. 一维数组 int a[3]={1,2,3}; 指向整型的指针 int *p=a; 二维数组 int a[3][2]={{1,2},{3,4},{5,6}}; 指向整型数组的指针 int (*p)[2]=a; (p指向a的第1行) 指向整型的指针 int *p=&a[0][0]; 或 int *p=a[0]; 或 int *p=(int*)a;2. 一维数组 int a[3]={1,2,3}; fun1(a) 函数原型可写为: void fun1(int *a) 或 void fun(int a[]) 二维数组 int a[3][2]={{1,2},{3,4},{5,6}}; fu 阅读全文
posted @ 2011-11-28 10:54 shiney 阅读(253) 评论(3) 推荐(0)
摘要:#include<stdio.h>void merge(const int array_a[],const int array_b[],int Temp_array[],int size_a,int size_b);void merge(const int array_a[],const int array_b[],int Temp_array[],int size_a,int size_b){ int tempPos=0,Lpos=0,Rpos=0; while((Lpos!=size_a)&&(Rpos!=size_b)) { if(array_a[Lpos]& 阅读全文
posted @ 2011-11-09 16:14 shiney 阅读(218) 评论(0) 推荐(0)
摘要:列一下我所认为的,你面试微软前必须要读的十本书:Code: The Hidden Language of Computer Hardware and Software (《编码的奥秘》)Computer System: A Programmer’s Approach (《深入理解计算机系统》) / Windows via C/C++ (《Windows核心编程》 / 《程序员的自我修养》Code Complete 2(《代码大全》)/ The Pragmatic Programmer (《程序员修炼之道》,我也把这本书称为《代码小全》)Programming Pearls (《编程珠玑》) / 阅读全文
posted @ 2011-11-09 09:50 shiney 阅读(325) 评论(0) 推荐(0)
摘要:#include<iostream.h>#include<string.h>#include<vector>#include<bitset>using namespace std;int main(){ vector<int> tt; int a; cout<<"Please input some numbers( q to quit): "<<endl; while((cin>>a)&&a!='q') { tt.push_back(a); cin 阅读全文
posted @ 2011-11-08 10:44 shiney 阅读(205) 评论(0) 推荐(0)
摘要:1. 包含头文件的两种格式 <>用于库文件 ""用于自定义的头文件 阅读全文
posted @ 2011-11-02 21:49 shiney 阅读(124) 评论(0) 推荐(0)