This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <assert.h> | |
| #include <malloc.h> | |
| #include <stdio.h> | |
| #include <string.h> | |
| namespace Character { | |
| bool isalphalower(char c) { return c >= 97 && c <= 122; } | |
| bool isalphaupper(char c) { return c >= 65 && c <= 90; } | |
| bool isalpha(char c) { return isalphalower(c) || isalphaupper(c); } | |
| bool isnumeric(char c) { return c >= 48 && c <= 57; } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = 'abcdefghijklmnopqrstuvwxyz'; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_space(ch) { | |
| return ' \r\n\t'.includes(ch); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = 'abcdefghijklmnopqrstuvwxyz'; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_space(ch) { | |
| return ' \r\n\t'.includes(ch); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = 'abcdefghijklmnopqrstuvwxyz'; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_space(ch) { | |
| return ' \r\n\t'.includes(ch); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = 'abcdefghijklmnopqrstuvwxyz'; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_space(ch) { | |
| return ' \r\n\t'.includes(ch); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = 'abcdefghijklmnopqrstuvwxyz'; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_space(ch) { | |
| return ' \r\n\t'.includes(ch); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = "abcdefghijklmnopqrstuvwxyz"; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_numeric(ch) { | |
| return "0123456789".includes(ch); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| static is_alpha(ch) { | |
| const lower = "abcdefghijklmnopqrstuvwxyz"; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } | |
| static is_numeric(ch) { | |
| return "0123456789".includes(ch); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CharUtil { | |
| /** | |
| * Check if ch is a alphabetic letter | |
| * @param {string} ch | |
| * @returns {boolean} | |
| */ | |
| static is_alpha(ch) { | |
| const lower = "abcdefghijklmnopqrstuvwxyz"; | |
| return lower.includes(ch) || lower.toUpperCase().includes(ch); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| UwL6tArtWt1eAADNYv1WAAAAAAAAAAABAQAA+rQKEqYNUgAAzWL9VgAAAAAAAAAAAQEAAAEBAAWTmAUVfABGjJgFiVBORw0KGgoAAAANSUhEUgAAFXwAAABGCAYAAADRXpj8AAFL00lEQVR4XmMAgv/DARcVFf3n4OCg2C/Gxsb/3759+59UkJ6e/l9CQoKg/QICAv8PHjz4n1zw8ePH/6tWrfpfXFz8f+7cuf9bW1v/Ozk5/WdiYgLbPWnSpP+Ugnv37v2vq6v7v3Llyv/fv3//T0vw9+/f/x8+fPj/48eP/9++fft/4MCB/xkZGf+nT59OFWv37dv3v7y8/D8ofnp7e/8/evTo/7Nnz/4/fPjwf3d39//Y2Nj/zc3NZMU5IQf++/ePpmG3c+dOeHrLycmBhyO1LV26dOl/RkZGsF1CQkL/t2zZ8v/ly5dkWQMKd+R8ys3N/V9YWPg/Jycn2Hx2dnZwmv79+zfJ5v/58+c/COMKd1C6njZtGjj/PH369D+t4+f/AAMeHp7/oqKi/2VlZf+rqan919PT+29mZvbfzs7uf2Bg4P/MzMz/wcHB/2NiYv6D4vjXr18kuxhb3QFKK56env+fP39OVgiA4vDu3bv/t2/f/n/y5MlYy1R5efn/9vb2/69duwa34+vXr/9VVVXh6pmZmf/39PT8x5eWfv78CVYzXOrBUX8wDOr2DKwcHenxBMq/oPbFpk2b/u/evft/fn4+XeKN3CIZ1A6ytbUFuxHkdlD59H8UDEgIgMr5tra2/1euXBlWMfDly5f/1dXV/y9evEh1f4HqwIKCAoJ5bDRJD88QAPWvTpw4Ae43hoeH/7eysoK36YeLj3G1RUfbRAz/R8NgYMKAj4/vPxcXF0b4g8ZrQHlwNF4g8QIaF9PW1v6voqLyHxRmo+1k1PQKSi+gMAH1aWmRZkDjL1JSUv+lpaX/y8jI/GdjYyO6zMBXf2zduvU/aIyHFDevWbMGw0iQvwMCAv6D0gg1/Q8aIwGN27KwsNCsjASN |
OlderNewer