摘要:
int add(int a, int b){ long long temp; while(a){ temp = a&b; b = a^b; a=temp*2; } return b; } 阅读全文
摘要:
#define MAXLEN 10001 int* addToArrayForm(int* A, int ASize, int K, int* returnSize){ int* arr=(int*)calloc(sizeof(int),MAXLEN); int i, pst=MAXLEN, fla 阅读全文
摘要:
typedef struct { int front[2]; int rear[2]; int* arr[2][20001]; int noAnimal[2]; } AnimalShelf; AnimalShelf* animalShelfCreate() { AnimalShelf* obj=(A 阅读全文
摘要:
int arrangeCoins(int n){ int i; for(i=1; n>=0; i++) n-=i; return i-2; } 阅读全文
摘要:
/*C语言*/ int cmp(const void* a,const void* b){ return *(int*)a>*(int*)b; } int arrayPairSum(int* nums, int numsSize){ int sum=0, i; qsort(nums,numsSize 阅读全文