Skip to content

Commit 8fed003

Browse files
committed
feat(string): adding string constants, like python has
1 parent 9b247f1 commit 8fed003

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

String.ark

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,39 @@
1+
# @brief Upper and lowercase ASCII letters
2+
# @author https://github.com/SuperFola
3+
(let asciiLetters "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ")
4+
5+
# @brief Lowercase ASCII letters
6+
# @author https://github.com/SuperFola
7+
(let asciiLowercase "abcdefghijklmnopqrstuvwxyz")
8+
9+
# @brief Uppercase ASCII letters
10+
# @author https://github.com/SuperFola
11+
(let asciiUppercase "ABCDEFGHIJKLMNOPQRSTUVWXYZ")
12+
13+
# @brief Digits used to represent decimal
14+
# @author https://github.com/SuperFola
15+
(let digits "0123456789")
16+
17+
# @brief Digits used to represent hexadecimal
18+
# @author https://github.com/SuperFola
19+
(let hexdigits "0123456789abcdefABCDEF")
20+
21+
# @brief Digits used to represent octal
22+
# @author https://github.com/SuperFola
23+
(let octdigits "01234567")
24+
25+
# @brief All printable characters
26+
# @author https://github.com/SuperFola
27+
(let printable "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~ \t\n\r")
28+
29+
# @brief Punctuation characters
30+
# @author https://github.com/SuperFola
31+
(let punctuation "!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~")
32+
33+
# @brief Whitespace characters
34+
# @author https://github.com/SuperFola
35+
(let whitespace " \t\n\r")
36+
137
# @brief Search a substring in a given String
238
# @details The original String is not modified. Return -1 when not found
339
# @param string the String to search in

0 commit comments

Comments
 (0)