Skip to content

Commit 394e49e

Browse files
committed
更新
1 parent 0c14d21 commit 394e49e

File tree

12 files changed

+109
-1
lines changed

12 files changed

+109
-1
lines changed
File renamed without changes.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
char * freqAlphabets(char * s){
2+
3+
int i = 0, j = i + 2;
4+
int k = 0;
5+
char *buf = calloc(1, 1000);
6+
7+
while(s[i] != '\0'){
8+
9+
if(s[i + 1] == '\0'){
10+
buf[k++] = s[i] + 0x30;
11+
return buf;
12+
}else if(s[j] == '#'){
13+
buf[k++] = (s[i] - 0x30) * 10 + (s[i + 1] - 0x30) + 0x60;
14+
i += 3;
15+
j += 3;
16+
continue;
17+
}else if(s[j] == '\0'){
18+
buf[k++] = s[i] + 0x30;
19+
buf[k++] = s[i + 1] + 0x30;
20+
return buf;
21+
}
22+
23+
buf[k++] = s[i] + 0x30;
24+
i++;j++;
25+
}
26+
return buf;
27+
}

C/15_3Sum/3Sum.c

+81
Large diffs are not rendered by default.
File renamed without changes.

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
# leetcode
1+
# leetcode

0 commit comments

Comments
 (0)