摘要:
1 class Solution { 2 public: 3 int singleNumber(int A[], int n) { 4 int i,j; 5 for(i=0; i<n; i++) 6 { 7 for(j... 阅读全文
摘要:
There areNchildren standing in a line. Each child is assigned a rating value.You are giving candies to these children subjected to the following requi... 阅读全文
摘要:
For example,Given{1,2,3,4}, reorder it to{1,4,2,3}. 1 /** 2 * Definition for singly-linked list. 3 * struct ListNode { 4 * int val; 5 * Li... 阅读全文
摘要:
1 /** 2 * Definition for singly-linked list. 3 * struct ListNode { 4 * int val; 5 * ListNode *next; 6 * ListNode(int x) : val(x), ne... 阅读全文