摘要: //利用循环一直到空指针然后申请数组通过递归一层层赋值并返回int* reversePrint(struct ListNode* head, int* returnSize){ if(head == NULL){ *returnSize = 0; return malloc(sizeof(int) 阅读全文
posted @ 2020-08-22 18:56 温暖了寂寞 阅读(112) 评论(0) 推荐(0) 编辑
摘要: int num = 0; void fun(int n,int** arr,int row,int start,int index,int count,int k) { count++; //用来表示当前第几步 if (count > k) return; for (int i=0; i<row; 阅读全文
posted @ 2020-08-22 15:56 温暖了寂寞 阅读(159) 评论(0) 推荐(0) 编辑
摘要: struct ListNode* deleteNode(struct ListNode* head, int val){ int count = 0; struct ListNode* ret = head; struct ListNode* pre = head; while(head!=NULL 阅读全文
posted @ 2020-08-22 11:05 温暖了寂寞 阅读(103) 评论(0) 推荐(0) 编辑
摘要: #define MAX_INT 2147483647 int min (int a, int b) { return a < b? a: b; } typedef struct { int min[20001]; int stack[20001]; int top; } MinStack; /** 阅读全文
posted @ 2020-08-22 10:51 温暖了寂寞 阅读(106) 评论(0) 推荐(0) 编辑