Skip to content

Commit cc5d2d5

Browse files
committedOct 16, 2021
code read example no 1
1 parent a6eb1e1 commit cc5d2d5

File tree

3 files changed

+51
-1
lines changed

3 files changed

+51
-1
lines changed
 

‎.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
text-file.txt

‎1.js

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
function funcOne(arg1){
2+
3+
let newArray = [];
4+
5+
for( let i = 0; i < arg1.length; i++){
6+
7+
if(arg1[i].charCodeAt(0) >= 97){
8+
newArray.push(arg1[i]);
9+
}
10+
}
11+
12+
return newArray.join("");
13+
14+
}
15+
//
16+
//
17+
//
18+
//
19+
//
20+
//
21+
//
22+
//
23+
//
24+
//
25+
//
26+
//
27+
//
28+
//
29+
//
30+
//
31+
//
32+
//
33+
//
34+
console.log(funcOne("A_lFGowJKer324cas12=-elDF235et897te56567rs"))

‎README.md

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,16 @@
1-
# code-read-examples
1+
# code-read-examples
2+
## @fac23
3+
4+
Code examples without notes and with deliberately obscure function, argument and variable names to be used as code reading exercises. Each one comes with a clue in the form of a function call that can be run from the command line.
5+
6+
```sh
7+
function funcOne(arg1) {
8+
9+
...
10+
11+
return result
12+
}
13+
14+
```
15+
16+
HT @jacksongabbard for suggesting this format

0 commit comments

Comments
 (0)
Please sign in to comment.