trackler 2.2.1.94 → 2.2.1.95
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/trackler/version.rb +1 -1
- data/problem-specifications/exercises/anagram/canonical-data.json +1 -37
- data/tracks/crystal/exercises/hello-world/{HINTS.md → .meta/hints.md} +0 -0
- data/tracks/java/exercises/prime-factors/.meta/hints.md +58 -0
- data/tracks/java/exercises/prime-factors/README.md +62 -0
- data/tracks/java/exercises/robot-name/.meta/hints.md +58 -0
- data/tracks/java/exercises/robot-name/README.md +62 -0
- data/tracks/java/exercises/robot-simulator/src/test/java/RobotTest.java +9 -5
- data/tracks/java/exercises/run-length-encoding/.meta/hints.md +58 -0
- data/tracks/java/exercises/run-length-encoding/README.md +62 -0
- data/tracks/javascript/config/exercise_readme.go.tmpl +26 -4
- data/tracks/javascript/exercises/accumulate/README.md +16 -16
- data/tracks/javascript/exercises/acronym/README.md +15 -13
- data/tracks/javascript/exercises/all-your-base/README.md +16 -14
- data/tracks/javascript/exercises/allergies/README.md +15 -13
- data/tracks/javascript/exercises/alphametics/README.md +17 -15
- data/tracks/javascript/exercises/anagram/README.md +15 -12
- data/tracks/javascript/exercises/atbash-cipher/README.md +17 -13
- data/tracks/javascript/exercises/beer-song/README.md +17 -14
- data/tracks/javascript/exercises/binary/README.md +17 -12
- data/tracks/javascript/exercises/binary-search/README.md +15 -12
- data/tracks/javascript/exercises/binary-search-tree/README.md +15 -12
- data/tracks/javascript/exercises/bob/README.md +17 -12
- data/tracks/javascript/exercises/bowling/README.md +38 -21
- data/tracks/javascript/exercises/bracket-push/README.md +15 -12
- data/tracks/javascript/exercises/change/README.md +31 -17
- data/tracks/javascript/exercises/circular-buffer/README.md +28 -18
- data/tracks/javascript/exercises/clock/README.md +15 -12
- data/tracks/javascript/exercises/collatz-conjecture/README.md +15 -12
- data/tracks/javascript/exercises/connect/README.md +17 -16
- data/tracks/javascript/exercises/crypto-square/README.md +25 -20
- data/tracks/javascript/exercises/custom-set/README.md +15 -13
- data/tracks/javascript/exercises/diamond/README.md +21 -18
- data/tracks/javascript/exercises/difference-of-squares/README.md +16 -13
- data/tracks/javascript/exercises/diffie-hellman/README.md +15 -17
- data/tracks/javascript/exercises/etl/README.md +18 -13
- data/tracks/javascript/exercises/flatten-array/README.md +16 -14
- data/tracks/javascript/exercises/food-chain/README.md +16 -13
- data/tracks/javascript/exercises/forth/README.md +17 -18
- data/tracks/javascript/exercises/gigasecond/README.md +15 -12
- data/tracks/javascript/exercises/grade-school/README.md +15 -13
- data/tracks/javascript/exercises/grains/README.md +15 -13
- data/tracks/javascript/exercises/hamming/README.md +15 -12
- data/tracks/javascript/exercises/hello-world/README.md +15 -12
- data/tracks/javascript/exercises/hexadecimal/README.md +15 -12
- data/tracks/javascript/exercises/isbn-verifier/README.md +44 -36
- data/tracks/javascript/exercises/isogram/README.md +17 -13
- data/tracks/javascript/exercises/kindergarten-garden/README.md +28 -25
- data/tracks/javascript/exercises/largest-series-product/README.md +15 -12
- data/tracks/javascript/exercises/leap/README.md +16 -13
- data/tracks/javascript/exercises/linked-list/README.md +25 -22
- data/tracks/javascript/exercises/list-ops/README.md +15 -13
- data/tracks/javascript/exercises/luhn/README.md +22 -19
- data/tracks/javascript/exercises/matrix/README.md +21 -16
- data/tracks/javascript/exercises/meetup/README.md +31 -25
- data/tracks/javascript/exercises/minesweeper/README.md +15 -13
- data/tracks/javascript/exercises/nth-prime/README.md +15 -12
- data/tracks/javascript/exercises/nucleotide-count/README.md +23 -34
- data/tracks/javascript/exercises/ocr-numbers/README.md +21 -18
- data/tracks/javascript/exercises/octal/README.md +21 -14
- data/tracks/javascript/exercises/palindrome-products/README.md +29 -27
- data/tracks/javascript/exercises/pangram/README.md +16 -13
- data/tracks/javascript/exercises/pascals-triangle/README.md +17 -14
- data/tracks/javascript/exercises/perfect-numbers/README.md +17 -14
- data/tracks/javascript/exercises/phone-number/README.md +19 -15
- data/tracks/javascript/exercises/pig-latin/README.md +15 -12
- data/tracks/javascript/exercises/point-mutations/README.md +15 -12
- data/tracks/javascript/exercises/prime-factors/README.md +15 -12
- data/tracks/javascript/exercises/protein-translation/README.md +19 -17
- data/tracks/javascript/exercises/proverb/README.md +29 -21
- data/tracks/javascript/exercises/pythagorean-triplet/README.md +18 -15
- data/tracks/javascript/exercises/queen-attack/README.md +16 -13
- data/tracks/javascript/exercises/raindrops/README.md +15 -12
- data/tracks/javascript/exercises/reverse-string/README.md +19 -15
- data/tracks/javascript/exercises/rna-transcription/README.md +16 -13
- data/tracks/javascript/exercises/robot-name/README.md +15 -12
- data/tracks/javascript/exercises/robot-simulator/README.md +15 -12
- data/tracks/javascript/exercises/roman-numerals/README.md +16 -13
- data/tracks/javascript/exercises/run-length-encoding/README.md +19 -16
- data/tracks/javascript/exercises/saddle-points/README.md +16 -13
- data/tracks/javascript/exercises/say/README.md +15 -12
- data/tracks/javascript/exercises/scrabble-score/README.md +18 -13
- data/tracks/javascript/exercises/secret-handshake/README.md +16 -13
- data/tracks/javascript/exercises/series/README.md +15 -12
- data/tracks/javascript/exercises/sieve/README.md +15 -12
- data/tracks/javascript/exercises/simple-cipher/README.md +19 -18
- data/tracks/javascript/exercises/simple-linked-list/README.md +15 -12
- data/tracks/javascript/exercises/space-age/README.md +16 -13
- data/tracks/javascript/exercises/strain/README.md +15 -12
- data/tracks/javascript/exercises/sublist/README.md +14 -17
- data/tracks/javascript/exercises/sum-of-multiples/README.md +19 -19
- data/tracks/javascript/exercises/transpose/README.md +15 -12
- data/tracks/javascript/exercises/triangle/README.md +24 -18
- data/tracks/javascript/exercises/trinary/README.md +16 -13
- data/tracks/javascript/exercises/twelve-days/README.md +17 -16
- data/tracks/javascript/exercises/two-bucket/README.md +25 -22
- data/tracks/javascript/exercises/two-fer/README.md +19 -14
- data/tracks/javascript/exercises/word-count/README.md +16 -14
- data/tracks/javascript/exercises/wordy/README.md +15 -17
- data/tracks/javascript/exercises/zipper/README.md +20 -18
- data/tracks/perl6/docs/ABOUT.md +12 -21
- metadata +6 -4
- data/tracks/javascript/docs/EXERCISE_README_INSERT.md +0 -22
@@ -2,45 +2,51 @@
|
|
2
2
|
|
3
3
|
Determine if a triangle is equilateral, isosceles, or scalene.
|
4
4
|
|
5
|
-
An _equilateral_ triangle has all three sides the same length
|
5
|
+
An _equilateral_ triangle has all three sides the same length.
|
6
|
+
|
6
7
|
An _isosceles_ triangle has at least two sides the same length. (It is sometimes
|
7
8
|
specified as having exactly two sides the same length, but for the purposes of
|
8
|
-
this exercise we'll say at least two.)
|
9
|
+
this exercise we'll say at least two.)
|
10
|
+
|
9
11
|
A _scalene_ triangle has all sides of different lengths.
|
10
12
|
|
11
13
|
## Note
|
12
14
|
|
13
|
-
For a shape to be a triangle at all, all sides have to be of length > 0, and
|
14
|
-
the sum of the lengths of any two sides must be greater than or equal to the
|
15
|
+
For a shape to be a triangle at all, all sides have to be of length > 0, and
|
16
|
+
the sum of the lengths of any two sides must be greater than or equal to the
|
15
17
|
length of the third side. See [Triangle Inequality](https://en.wikipedia.org/wiki/Triangle_inequality).
|
16
18
|
|
17
19
|
## Dig Deeper
|
18
20
|
|
19
|
-
The case where the sum of the lengths of two sides _equals_ that of the
|
20
|
-
third is known as a _degenerate_ triangle - it has zero area and looks like
|
21
|
+
The case where the sum of the lengths of two sides _equals_ that of the
|
22
|
+
third is known as a _degenerate_ triangle - it has zero area and looks like
|
21
23
|
a single line. Feel free to add your own code/tests to check for degenerate triangles.
|
24
|
+
|
22
25
|
## Setup
|
23
26
|
|
24
|
-
Go through the setup instructions for JavaScript to
|
25
|
-
|
27
|
+
Go through the setup instructions for JavaScript to install the
|
28
|
+
necessary dependencies:
|
26
29
|
|
27
30
|
http://exercism.io/languages/javascript/installation
|
28
31
|
|
29
|
-
##
|
30
|
-
|
31
|
-
Execute the tests with:
|
32
|
+
## Running the test suite
|
32
33
|
|
33
|
-
|
34
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
35
|
+
You can install it by opening a terminal window and running the
|
36
|
+
following command:
|
34
37
|
|
35
|
-
|
36
|
-
|
38
|
+
```sh
|
39
|
+
npm install -g jasmine
|
40
|
+
```
|
37
41
|
|
38
|
-
|
42
|
+
Run the test suite from the exercise directory with:
|
39
43
|
|
40
|
-
|
44
|
+
```sh
|
45
|
+
jasmine triangle.spec.js
|
46
|
+
```
|
41
47
|
|
42
|
-
|
43
|
-
changing `xit` to `it`.
|
48
|
+
In many test suites all but the first test have been marked "pending".
|
49
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
44
50
|
|
45
51
|
## Source
|
46
52
|
|
@@ -11,7 +11,7 @@ Trinary numbers contain three symbols: 0, 1, and 2.
|
|
11
11
|
The last place in a trinary number is the 1's place. The second to last
|
12
12
|
is the 3's place, the third to last is the 9's place, etc.
|
13
13
|
|
14
|
-
```
|
14
|
+
```shell
|
15
15
|
# "102012"
|
16
16
|
1 0 2 0 1 2 # the number
|
17
17
|
1*3^5 + 0*3^4 + 2*3^3 + 0*3^2 + 1*3^1 + 2*3^0 # the value
|
@@ -23,26 +23,29 @@ conversion, pretend it doesn't exist and implement it yourself.
|
|
23
23
|
|
24
24
|
## Setup
|
25
25
|
|
26
|
-
Go through the setup instructions for JavaScript to
|
27
|
-
|
26
|
+
Go through the setup instructions for JavaScript to install the
|
27
|
+
necessary dependencies:
|
28
28
|
|
29
29
|
http://exercism.io/languages/javascript/installation
|
30
30
|
|
31
|
-
##
|
31
|
+
## Running the test suite
|
32
32
|
|
33
|
-
|
33
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
34
|
+
You can install it by opening a terminal window and running the
|
35
|
+
following command:
|
34
36
|
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
test the Hello World exercise:
|
37
|
+
```sh
|
38
|
+
npm install -g jasmine
|
39
|
+
```
|
39
40
|
|
40
|
-
|
41
|
+
Run the test suite from the exercise directory with:
|
41
42
|
|
42
|
-
|
43
|
+
```sh
|
44
|
+
jasmine trinary.spec.js
|
45
|
+
```
|
43
46
|
|
44
|
-
|
45
|
-
changing `xit` to `it`.
|
47
|
+
In many test suites all but the first test have been marked "pending".
|
48
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
46
49
|
|
47
50
|
## Source
|
48
51
|
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Output the lyrics to 'The Twelve Days of Christmas'.
|
4
4
|
|
5
|
-
```
|
5
|
+
```text
|
6
6
|
On the first day of Christmas my true love gave to me, a Partridge in a Pear Tree.
|
7
7
|
|
8
8
|
On the second day of Christmas my true love gave to me, two Turtle Doves, and a Partridge in a Pear Tree.
|
@@ -28,34 +28,35 @@ On the eleventh day of Christmas my true love gave to me, eleven Pipers Piping,
|
|
28
28
|
On the twelfth day of Christmas my true love gave to me, twelve Drummers Drumming, eleven Pipers Piping, ten Lords-a-Leaping, nine Ladies Dancing, eight Maids-a-Milking, seven Swans-a-Swimming, six Geese-a-Laying, five Gold Rings, four Calling Birds, three French Hens, two Turtle Doves, and a Partridge in a Pear Tree.
|
29
29
|
```
|
30
30
|
|
31
|
-
|
32
31
|
## Setup
|
33
32
|
|
34
|
-
Go through the setup instructions for JavaScript to
|
35
|
-
|
33
|
+
Go through the setup instructions for JavaScript to install the
|
34
|
+
necessary dependencies:
|
36
35
|
|
37
36
|
http://exercism.io/languages/javascript/installation
|
38
37
|
|
39
|
-
##
|
40
|
-
|
41
|
-
Execute the tests with:
|
38
|
+
## Running the test suite
|
42
39
|
|
43
|
-
|
40
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
41
|
+
You can install it by opening a terminal window and running the
|
42
|
+
following command:
|
44
43
|
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
jasmine hello-world.spec.js
|
44
|
+
```sh
|
45
|
+
npm install -g jasmine
|
46
|
+
```
|
49
47
|
|
50
|
-
|
48
|
+
Run the test suite from the exercise directory with:
|
51
49
|
|
52
|
-
|
53
|
-
|
50
|
+
```sh
|
51
|
+
jasmine twelve-days.spec.js
|
52
|
+
```
|
54
53
|
|
54
|
+
In many test suites all but the first test have been marked "pending".
|
55
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
55
56
|
|
56
57
|
## Source
|
57
58
|
|
58
59
|
Wikipedia [http://en.wikipedia.org/wiki/The_Twelve_Days_of_Christmas_(song)](http://en.wikipedia.org/wiki/The_Twelve_Days_of_Christmas_(song))
|
59
60
|
|
60
61
|
## Submitting Incomplete Solutions
|
61
|
-
It's possible to submit an incomplete solution so you can see how others have completed the exercise.
|
62
|
+
It's possible to submit an incomplete solution so you can see how others have completed the exercise.
|
@@ -4,22 +4,22 @@ Given two buckets of different size, demonstrate how to measure an exact number
|
|
4
4
|
|
5
5
|
Since this mathematical problem is fairly subject to interpretation / individual approach, the tests have been written specifically to expect one overarching solution.
|
6
6
|
|
7
|
-
To help, the tests provide you with which bucket to fill first. That means, when starting with the larger bucket full, you are NOT allowed at any point to have the smaller bucket full and the larger bucket empty (aka, the opposite starting point); that would defeat the purpose of comparing both approaches!
|
7
|
+
To help, the tests provide you with which bucket to fill first. That means, when starting with the larger bucket full, you are NOT allowed at any point to have the smaller bucket full and the larger bucket empty (aka, the opposite starting point); that would defeat the purpose of comparing both approaches!
|
8
8
|
|
9
9
|
Your program will take as input:
|
10
|
-
- the size of bucket one
|
11
|
-
- the size of bucket two
|
12
|
-
- the desired number of liters to reach
|
13
|
-
- which bucket to fill first,
|
10
|
+
- the size of bucket one
|
11
|
+
- the size of bucket two
|
12
|
+
- the desired number of liters to reach
|
13
|
+
- which bucket to fill first, either bucket one or bucket two
|
14
14
|
|
15
15
|
Your program should determine:
|
16
|
-
- the total number of "moves" it should take to reach the desired number of liters, including the first fill
|
17
|
-
- which bucket should end up with the desired number of liters (let's say this is bucket A) -
|
18
|
-
- how many liters are left in the other bucket (bucket B)
|
16
|
+
- the total number of "moves" it should take to reach the desired number of liters, including the first fill
|
17
|
+
- which bucket should end up with the desired number of liters (let's say this is bucket A) - either bucket one or bucket two
|
18
|
+
- how many liters are left in the other bucket (bucket B)
|
19
19
|
|
20
|
-
Note: any time a change is made to either or both buckets counts as one (1) move.
|
20
|
+
Note: any time a change is made to either or both buckets counts as one (1) move.
|
21
21
|
|
22
|
-
Example:
|
22
|
+
Example:
|
23
23
|
Bucket one can hold up to 7 liters, and bucket two can hold up to 11 liters. Let's say bucket one, at a given step, is holding 7 liters, and bucket two is holding 8 liters (7,8). If you empty bucket one and make no change to bucket two, leaving you with 0 liters and 8 liters respectively (0,8), that counts as one "move". Instead, if you had poured from bucket one into bucket two until bucket two was full, leaving you with 4 liters in bucket one and 11 liters in bucket two (4,11), that would count as only one "move" as well.
|
24
24
|
|
25
25
|
To conclude, the only valid moves are:
|
@@ -31,26 +31,29 @@ Written with <3 at [Fullstack Academy](http://www.fullstackacademy.com/) by [Lin
|
|
31
31
|
|
32
32
|
## Setup
|
33
33
|
|
34
|
-
Go through the setup instructions for JavaScript to
|
35
|
-
|
34
|
+
Go through the setup instructions for JavaScript to install the
|
35
|
+
necessary dependencies:
|
36
36
|
|
37
37
|
http://exercism.io/languages/javascript/installation
|
38
38
|
|
39
|
-
##
|
39
|
+
## Running the test suite
|
40
40
|
|
41
|
-
|
41
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
42
|
+
You can install it by opening a terminal window and running the
|
43
|
+
following command:
|
42
44
|
|
43
|
-
|
45
|
+
```sh
|
46
|
+
npm install -g jasmine
|
47
|
+
```
|
44
48
|
|
45
|
-
|
46
|
-
test the Hello World exercise:
|
49
|
+
Run the test suite from the exercise directory with:
|
47
50
|
|
48
|
-
|
51
|
+
```sh
|
52
|
+
jasmine two-bucket.spec.js
|
53
|
+
```
|
49
54
|
|
50
|
-
In many test suites all but the first test have been
|
51
|
-
|
52
|
-
Once you get a test passing, you can unskip the next one by
|
53
|
-
changing `xit` to `it`.
|
55
|
+
In many test suites all but the first test have been marked "pending".
|
56
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
54
57
|
|
55
58
|
## Source
|
56
59
|
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
`Two-fer` or `2-fer` is short for two for one. One for you and one for me.
|
4
4
|
|
5
|
-
```
|
5
|
+
```text
|
6
6
|
"One for X, one for me."
|
7
7
|
```
|
8
8
|
|
@@ -11,31 +11,36 @@ When X is a name or "you".
|
|
11
11
|
If the given name is "Alice", the result should be "One for Alice, one for me."
|
12
12
|
If no name is given, the result should be "One for you, one for me."
|
13
13
|
|
14
|
+
|
14
15
|
## Setup
|
15
16
|
|
16
|
-
Go through the setup instructions for JavaScript to
|
17
|
-
|
17
|
+
Go through the setup instructions for JavaScript to install the
|
18
|
+
necessary dependencies:
|
18
19
|
|
19
|
-
http://exercism.io/languages/javascript
|
20
|
+
http://exercism.io/languages/javascript/installation
|
20
21
|
|
21
|
-
##
|
22
|
+
## Running the test suite
|
22
23
|
|
23
|
-
|
24
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
25
|
+
You can install it by opening a terminal window and running the
|
26
|
+
following command:
|
24
27
|
|
25
|
-
|
28
|
+
```sh
|
29
|
+
npm install -g jasmine
|
30
|
+
```
|
26
31
|
|
27
|
-
|
28
|
-
test the Two Fer exercise:
|
32
|
+
Run the test suite from the exercise directory with:
|
29
33
|
|
30
|
-
|
34
|
+
```sh
|
35
|
+
jasmine two-fer.spec.js
|
36
|
+
```
|
31
37
|
|
32
|
-
|
33
|
-
you
|
38
|
+
In many test suites all but the first test have been marked "pending".
|
39
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
34
40
|
|
35
41
|
## Source
|
36
42
|
|
37
|
-
This is an exercise to introduce users to basic programming constructs, just after
|
43
|
+
This is an exercise to introduce users to basic programming constructs, just after Hello World. [https://en.wikipedia.org/wiki/Two-fer](https://en.wikipedia.org/wiki/Two-fer)
|
38
44
|
|
39
45
|
## Submitting Incomplete Solutions
|
40
46
|
It's possible to submit an incomplete solution so you can see how others have completed the exercise.
|
41
|
-
|
@@ -4,36 +4,38 @@ Given a phrase, count the occurrences of each word in that phrase.
|
|
4
4
|
|
5
5
|
For example for the input `"olly olly in come free"`
|
6
6
|
|
7
|
-
```
|
7
|
+
```text
|
8
8
|
olly: 2
|
9
9
|
in: 1
|
10
10
|
come: 1
|
11
11
|
free: 1
|
12
12
|
```
|
13
13
|
|
14
|
-
|
15
14
|
## Setup
|
16
15
|
|
17
|
-
Go through the setup instructions for JavaScript to
|
18
|
-
|
16
|
+
Go through the setup instructions for JavaScript to install the
|
17
|
+
necessary dependencies:
|
19
18
|
|
20
19
|
http://exercism.io/languages/javascript/installation
|
21
20
|
|
22
|
-
##
|
23
|
-
|
24
|
-
Execute the tests with:
|
21
|
+
## Running the test suite
|
25
22
|
|
26
|
-
|
23
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
24
|
+
You can install it by opening a terminal window and running the
|
25
|
+
following command:
|
27
26
|
|
28
|
-
|
29
|
-
|
27
|
+
```sh
|
28
|
+
npm install -g jasmine
|
29
|
+
```
|
30
30
|
|
31
|
-
|
31
|
+
Run the test suite from the exercise directory with:
|
32
32
|
|
33
|
-
|
33
|
+
```sh
|
34
|
+
jasmine word-count.spec.js
|
35
|
+
```
|
34
36
|
|
35
|
-
|
36
|
-
changing `xit` to `it`.
|
37
|
+
In many test suites all but the first test have been marked "pending".
|
38
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
37
39
|
|
38
40
|
## Source
|
39
41
|
|
@@ -2,7 +2,6 @@
|
|
2
2
|
|
3
3
|
Parse and evaluate simple math word problems returning the answer as an integer.
|
4
4
|
|
5
|
-
|
6
5
|
## Iteration 1 — Addition
|
7
6
|
|
8
7
|
Add two numbers together.
|
@@ -13,7 +12,6 @@ Evaluates to 18.
|
|
13
12
|
|
14
13
|
Handle large numbers and negative numbers.
|
15
14
|
|
16
|
-
|
17
15
|
## Iteration 2 — Subtraction, Multiplication and Division
|
18
16
|
|
19
17
|
Now, perform the other three operations.
|
@@ -30,7 +28,6 @@ Now, perform the other three operations.
|
|
30
28
|
|
31
29
|
5
|
32
30
|
|
33
|
-
|
34
31
|
## Iteration 3 — Multiple Operations
|
35
32
|
|
36
33
|
Handle a set of operations, in sequence.
|
@@ -46,7 +43,6 @@ left-to-right, _ignoring the typical order of operations._
|
|
46
43
|
|
47
44
|
15 (i.e. not 9)
|
48
45
|
|
49
|
-
|
50
46
|
## Bonus — Exponentials
|
51
47
|
|
52
48
|
If you'd like, handle exponentials.
|
@@ -55,29 +51,31 @@ If you'd like, handle exponentials.
|
|
55
51
|
|
56
52
|
32
|
57
53
|
|
58
|
-
|
59
54
|
## Setup
|
60
55
|
|
61
|
-
Go through the setup instructions for JavaScript to
|
62
|
-
|
56
|
+
Go through the setup instructions for JavaScript to install the
|
57
|
+
necessary dependencies:
|
63
58
|
|
64
59
|
http://exercism.io/languages/javascript/installation
|
65
60
|
|
66
|
-
##
|
67
|
-
|
68
|
-
Execute the tests with:
|
61
|
+
## Running the test suite
|
69
62
|
|
70
|
-
|
63
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
64
|
+
You can install it by opening a terminal window and running the
|
65
|
+
following command:
|
71
66
|
|
72
|
-
|
73
|
-
|
67
|
+
```sh
|
68
|
+
npm install -g jasmine
|
69
|
+
```
|
74
70
|
|
75
|
-
|
71
|
+
Run the test suite from the exercise directory with:
|
76
72
|
|
77
|
-
|
73
|
+
```sh
|
74
|
+
jasmine wordy.spec.js
|
75
|
+
```
|
78
76
|
|
79
|
-
|
80
|
-
changing `xit` to `it`.
|
77
|
+
In many test suites all but the first test have been marked "pending".
|
78
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
81
79
|
|
82
80
|
## Source
|
83
81
|
|
@@ -3,7 +3,7 @@
|
|
3
3
|
Creating a zipper for a binary tree.
|
4
4
|
|
5
5
|
[Zippers](https://en.wikipedia.org/wiki/Zipper_%28data_structure%29) are
|
6
|
-
a
|
6
|
+
a purely functional way of navigating within a data structure and
|
7
7
|
manipulating it. They essentially contain a data structure and a
|
8
8
|
pointer into that data structure (called the focus).
|
9
9
|
|
@@ -27,29 +27,31 @@ list of child nodes) a zipper might support these operations:
|
|
27
27
|
`next` node if possible otherwise to the `prev` node if possible,
|
28
28
|
otherwise to the parent node, returns a new zipper)
|
29
29
|
|
30
|
-
|
30
|
+
## Setup
|
31
31
|
|
32
|
-
|
33
|
-
|
32
|
+
Go through the setup instructions for JavaScript to install the
|
33
|
+
necessary dependencies:
|
34
34
|
|
35
|
-
|
35
|
+
http://exercism.io/languages/javascript/installation
|
36
36
|
|
37
|
-
|
37
|
+
## Running the test suite
|
38
38
|
|
39
|
-
|
39
|
+
The provided test suite uses [Jasmine](https://jasmine.github.io/).
|
40
|
+
You can install it by opening a terminal window and running the
|
41
|
+
following command:
|
40
42
|
|
41
|
-
|
43
|
+
```sh
|
44
|
+
npm install -g jasmine
|
45
|
+
```
|
42
46
|
|
43
|
-
|
44
|
-
test the Hello World exercise:
|
47
|
+
Run the test suite from the exercise directory with:
|
45
48
|
|
46
|
-
|
49
|
+
```sh
|
50
|
+
jasmine zipper.spec.js
|
51
|
+
```
|
47
52
|
|
48
|
-
|
53
|
+
In many test suites all but the first test have been marked "pending".
|
54
|
+
Once you get a test passing, activate the next one by changing `xit` to `it`.
|
49
55
|
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
## Submitting Incomplete Solutions
|
55
|
-
It's possible to submit an incomplete solution so you can see how others have completed the exercise.
|
56
|
+
## Submitting Incomplete Solutions
|
57
|
+
It's possible to submit an incomplete solution so you can see how others have completed the exercise.
|
data/tracks/perl6/docs/ABOUT.md
CHANGED
@@ -1,24 +1,15 @@
|
|
1
|
-
Perl 6 is a clean, modern, multi-paradigm language; it offers procedural,
|
2
|
-
|
3
|
-
flexible language, adapting to your style of programming, whether that be quick
|
4
|
-
oneliners for sysadmins, scripts to manage a database import, or the full stack
|
5
|
-
of modules necessary to realise an entire website.
|
1
|
+
Perl 6 is a clean, modern, multi-paradigm language; it offers procedural, object-oriented AND functional programming methodologies.
|
2
|
+
It is a supremely flexible language, adapting to your style of programming, whether that be quick oneliners for sysadmins, scripts to manage a database import, or the full stack of modules necessary to realise an entire website.
|
6
3
|
|
7
|
-
Perl 6 enhances Perl’s longterm appeal with a proper object system including
|
8
|
-
|
9
|
-
|
10
|
-
success and learning from the issues of the past. We believe Perl 6 is a
|
11
|
-
language that will last for decades as it has been conceived to adapt to future
|
12
|
-
trends and is flexible in its usage with other languages.
|
4
|
+
Perl 6 enhances Perl’s longterm appeal with a proper object system including roles, threading and multimethod dispatch.
|
5
|
+
It has spent a long time coming to fruition and has learned from other programming languages, building on their success and learning from the issues of the past.
|
6
|
+
We believe Perl 6 is a language that will last for decades as it has been conceived to adapt to future trends and is flexible in its usage with other languages.
|
13
7
|
|
14
|
-
Perl 6 learns from other languages.
|
15
|
-
(simplified to a handful of methods); Foreign-function interfaces from Lisp make
|
16
|
-
|
17
|
-
|
18
|
-
you tackle huge parsing tasks. Strictures and warnings are now automatic,
|
19
|
-
cutting out huge swathes of potential errors.
|
8
|
+
Perl 6 learns from other languages.
|
9
|
+
For instance: taking threading from Java (simplified to a handful of methods); Foreign-function interfaces from Lisp make accessing libraries as simple as one line of code.
|
10
|
+
Regular expressions are now turned up to 11 with the introduction of Parser Expression Grammars, which let you tackle huge parsing tasks.
|
11
|
+
Strictures and warnings are now automatic, cutting out huge swathes of potential errors.
|
20
12
|
|
21
|
-
Perl 6’s mottos remain the same as Perl:
|
22
|
-
Perl is designed to make the easy jobs easy, without making the hard jobs
|
23
|
-
|
24
|
-
-Ofun (optimized for fun) added.
|
13
|
+
Perl 6’s mottos remain the same as Perl:
|
14
|
+
“Perl is different. In a nutshell, Perl is designed to make the easy jobs easy, without making the hard jobs impossible.” and “There Is More Than One Way To Do It”.
|
15
|
+
Now with even more -Ofun (optimized for fun) added.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: trackler
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.1.
|
4
|
+
version: 2.2.1.95
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Katrina Owen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-01-
|
11
|
+
date: 2018-01-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubyzip
|
@@ -2308,7 +2308,7 @@ files:
|
|
2308
2308
|
- tracks/crystal/exercises/hamming/spec/hamming_spec.cr
|
2309
2309
|
- tracks/crystal/exercises/hamming/src/example.cr
|
2310
2310
|
- tracks/crystal/exercises/hamming/src/hamming.cr
|
2311
|
-
- tracks/crystal/exercises/hello-world/
|
2311
|
+
- tracks/crystal/exercises/hello-world/.meta/hints.md
|
2312
2312
|
- tracks/crystal/exercises/hello-world/README.md
|
2313
2313
|
- tracks/crystal/exercises/hello-world/spec/hello_world_spec.cr
|
2314
2314
|
- tracks/crystal/exercises/hello-world/src/example.cr
|
@@ -7618,6 +7618,7 @@ files:
|
|
7618
7618
|
- tracks/java/exercises/poker/build.gradle
|
7619
7619
|
- tracks/java/exercises/poker/src/main/java/.keep
|
7620
7620
|
- tracks/java/exercises/poker/src/test/java/PokerTest.java
|
7621
|
+
- tracks/java/exercises/prime-factors/.meta/hints.md
|
7621
7622
|
- tracks/java/exercises/prime-factors/.meta/src/reference/java/PrimeFactorsCalculator.java
|
7622
7623
|
- tracks/java/exercises/prime-factors/.meta/version
|
7623
7624
|
- tracks/java/exercises/prime-factors/README.md
|
@@ -7676,6 +7677,7 @@ files:
|
|
7676
7677
|
- tracks/java/exercises/rna-transcription/build.gradle
|
7677
7678
|
- tracks/java/exercises/rna-transcription/src/main/java/RnaTranscription.java
|
7678
7679
|
- tracks/java/exercises/rna-transcription/src/test/java/RnaTranscriptionTest.java
|
7680
|
+
- tracks/java/exercises/robot-name/.meta/hints.md
|
7679
7681
|
- tracks/java/exercises/robot-name/.meta/src/reference/java/Robot.java
|
7680
7682
|
- tracks/java/exercises/robot-name/README.md
|
7681
7683
|
- tracks/java/exercises/robot-name/build.gradle
|
@@ -7702,6 +7704,7 @@ files:
|
|
7702
7704
|
- tracks/java/exercises/rotational-cipher/build.gradle
|
7703
7705
|
- tracks/java/exercises/rotational-cipher/src/main/java/RotationalCipher.java
|
7704
7706
|
- tracks/java/exercises/rotational-cipher/src/test/java/RotationalCipherTest.java
|
7707
|
+
- tracks/java/exercises/run-length-encoding/.meta/hints.md
|
7705
7708
|
- tracks/java/exercises/run-length-encoding/.meta/src/reference/java/RunLengthEncoding.java
|
7706
7709
|
- tracks/java/exercises/run-length-encoding/README.md
|
7707
7710
|
- tracks/java/exercises/run-length-encoding/build.gradle
|
@@ -7868,7 +7871,6 @@ files:
|
|
7868
7871
|
- tracks/javascript/config/exercise_readme.go.tmpl
|
7869
7872
|
- tracks/javascript/config/maintainers.json
|
7870
7873
|
- tracks/javascript/docs/ABOUT.md
|
7871
|
-
- tracks/javascript/docs/EXERCISE_README_INSERT.md
|
7872
7874
|
- tracks/javascript/docs/INSTALLATION.md
|
7873
7875
|
- tracks/javascript/docs/LEARNING.md
|
7874
7876
|
- tracks/javascript/docs/RESOURCES.md
|
@@ -1,22 +0,0 @@
|
|
1
|
-
## Setup
|
2
|
-
|
3
|
-
Go through the setup instructions for JavaScript to
|
4
|
-
install the necessary dependencies:
|
5
|
-
|
6
|
-
http://exercism.io/languages/javascript
|
7
|
-
|
8
|
-
## Making the Test Suite Pass
|
9
|
-
|
10
|
-
Execute the tests with:
|
11
|
-
|
12
|
-
jasmine <exercise-name>.spec.js
|
13
|
-
|
14
|
-
Replace `<exercise-name>` with the name of the current exercise. E.g., to
|
15
|
-
test the Hello World exercise:
|
16
|
-
|
17
|
-
jasmine hello-world.spec.js
|
18
|
-
|
19
|
-
In many test suites all but the first test have been skipped.
|
20
|
-
|
21
|
-
Once you get a test passing, you can unskip the next one by
|
22
|
-
changing `xit` to `it`.
|