Skip to content

Commit eacc900

Browse files
committed
Regenerate READMEs
Skipped Bob since the README change is for a newer version than the current Java test suite.
1 parent 98e8464 commit eacc900

13 files changed

Lines changed: 74 additions & 61 deletions

File tree

‎exercises/beer-song/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Beer Song
22

3-
Produce the lyrics to that beloved classic, that field-trip favorite: 99 Bottles of Beer on the Wall.
3+
Recite the lyrics to that beloved classic, that field-trip favorite: 99 Bottles of Beer on the Wall.
44

55
Note that not all verses are identical.
66

‎exercises/house/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# House
22

3-
Output the nursery rhyme 'This is the House that Jack Built'.
3+
Recite the nursery rhyme 'This is the House that Jack Built'.
44

55
> [The] process of placing a phrase of clause within another phrase of
66
> clause is called embedding. It is through the processes of recursion

‎exercises/isbn-verifier/README.md‎

Lines changed: 27 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,45 @@
1-
Check if a given ISBN-10 is valid.
1+
# Isbn Verifier
22

3-
## Functionality
3+
The [ISBN-10 verification process](https://en.wikipedia.org/wiki/International_Standard_Book_Number) is used to validate book identification
4+
numbers. These normally contain dashes and look like: `3-598-21508-8`
45

5-
Given an unknown string the program should check if the provided string is a valid ISBN-10.
6-
Putting this into place requires some thinking about preprocessing/parsing of the string prior to calculating the check digit for the ISBN.
6+
## ISBN
77

8-
The program should allow for ISBN-10 without the separating dashes to be verified as well.
8+
The ISBN-10 format is 9 digits (0 to 9) plus one check character (either a digit or an X only). In the case the check character is an X, this represents the value '10'. These may be communicated with or without hyphens, and can be checked for their validity by the following formula:
99

10-
## ISBN
10+
```
11+
(x1 * 10 + x2 * 9 + x3 * 8 + x4 * 7 + x5 * 6 + x6 * 5 + x7 * 4 + x8 * 3 + x9 * 2 + x10 * 1) mod 11 == 0
12+
```
1113

12-
Let's take a random ISBN-10 number, say `3-598-21508-8` for this.
13-
The first digit block indicates the group where the ISBN belongs. Groups can consist of shared languages, geographic regions or countries. The leading '3' signals this ISBN is from a german speaking country.
14-
The following number block is to identify the publisher. Since this is a three digit publisher number there is a 5 digit title number for this book.
15-
The last digit in the ISBN is the check digit which is used to detect read errors.
14+
If the result is 0, then it is a valid ISBN-10, otherwise it is invalid.
1615

17-
The first 9 digits in the ISBN have to be between 0 and 9.
18-
The check digit can additionally be an 'X' to allow 10 to be a valid check digit as well.
16+
## Example
1917

20-
A valid ISBN-10 is calculated with this formula `(x1 * 10 + x2 * 9 + x3 * 8 + x4 * 7 + x5 * 6 + x6 * 5 + x7 * 4 + x8 * 3 + x9 * 2 + x10 * 1) mod 11 == 0`
21-
So for our example ISBN this means:
22-
(3 * 10 + 5 * 9 + 9 * 8 + 8 * 7 + 2 * 6 + 1 * 5 + 5 * 4 + 0 * 3 + 8 * 2 + 8 * 1) mod 11 = 0
18+
Let's take the ISBN-10 `3-598-21508-8`. We plug it in to the formula, and get:
19+
```
20+
(3 * 10 + 5 * 9 + 9 * 8 + 8 * 7 + 2 * 6 + 1 * 5 + 5 * 4 + 0 * 3 + 8 * 2 + 8 * 1) mod 11 == 0
21+
```
22+
23+
Since the result is 0, this proves that our ISBN is valid.
24+
25+
## Task
26+
27+
Given a string the program should check if the provided string is a valid ISBN-10.
28+
Putting this into place requires some thinking about preprocessing/parsing of the string prior to calculating the check digit for the ISBN.
29+
30+
The program should be able to verify ISBN-10 both with and without separating dashes.
2331

24-
Which proves that the ISBN is valid.
2532

2633
## Caveats
2734

28-
Converting from string to number can be tricky in certain languages.
29-
It's getting even trickier since the check-digit of an ISBN-10 can be 'X'.
35+
Converting from strings to numbers can be tricky in certain languages.
36+
Now, it's even trickier since the check digit of an ISBN-10 may be 'X' (representing '10'). For instance `3-598-21507-X` is a valid ISBN-10.
3037

3138
## Bonus tasks
3239

33-
* Generate a valid ISBN-13 from the input ISBN-10 (and maybe verify it again with a derived verifier)
34-
35-
* Generate valid ISBN, maybe even from a given starting ISBN
40+
* Generate a valid ISBN-13 from the input ISBN-10 (and maybe verify it again with a derived verifier).
3641

42+
* Generate valid ISBN, maybe even from a given starting ISBN.
3743
# Running the tests
3844

3945
You can run all the tests for an exercise by entering

‎exercises/kindergarten-garden/README.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ actual dirt, and grow actual plants.
99

1010
They've chosen to grow grass, clover, radishes, and violets.
1111

12-
To this end, the children have put little cups along the window sills, and
13-
planted one type of plant in each cup, choosing randomly from the available
12+
To this end, the children have put little cups along the window sills, and
13+
planted one type of plant in each cup, choosing randomly from the available
1414
types of seeds.
1515

1616
```text
@@ -25,7 +25,7 @@ There are 12 children in the class:
2525
- Eve, Fred, Ginny, Harriet,
2626
- Ileana, Joseph, Kincaid, and Larry.
2727

28-
Each child gets 4 cups, two on each row. Their teacher assigns cups to
28+
Each child gets 4 cups, two on each row. Their teacher assigns cups to
2929
the children alphabetically by their names.
3030

3131
The following diagram represents Alice's plants:

‎exercises/meetup/README.md‎

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,25 +2,29 @@
22

33
Calculate the date of meetups.
44

5-
Typically meetups happen on the same day of the week. In this exercise, you will take
6-
a description of a meetup date, and return the actual meetup date.
5+
Typically meetups happen on the same day of the week. In this exercise, you
6+
will take a description of a meetup date, and return the actual meetup date.
77

88
Examples of general descriptions are:
99

10-
- the first Monday of January 2017
11-
- the third Tuesday of January 2017
12-
- the Wednesteenth of January 2017
13-
- the last Thursday of January 2017
10+
- The first Monday of January 2017
11+
- The third Tuesday of January 2017
12+
- The wednesteenth of January 2017
13+
- The last Thursday of January 2017
1414

15-
Note that "Monteenth", "Tuesteenth", etc are all made up words. There
16-
was a meetup whose members realized that there are exactly 7 numbered days in a month that
17-
end in '-teenth'. Therefore, one is guaranteed that each day of the week
15+
The descriptors you are expected to parse are:
16+
first, second, third, fourth, fifth, last, monteenth, tuesteenth, wednesteenth,
17+
thursteenth, friteenth, saturteenth, sunteenth
18+
19+
Note that "monteenth", "tuesteenth", etc are all made up words. There was a
20+
meetup whose members realized that there are exactly 7 numbered days in a month
21+
that end in '-teenth'. Therefore, one is guaranteed that each day of the week
1822
(Monday, Tuesday, ...) will have exactly one date that is named with '-teenth'
1923
in every month.
2024

21-
Given examples of a meetup dates, each containing a month, day, year, and descriptor
22-
(first, second, teenth, etc), calculate the date of the actual meetup.
23-
For example, if given "First Monday of January 2017", the correct meetup date is 2017/1/2
25+
Given examples of a meetup dates, each containing a month, day, year, and
26+
descriptor calculate the date of the actual meetup. For example, if given
27+
"The first Monday of January 2017", the correct meetup date is 2017/1/2.
2428

2529
# Running the tests
2630

‎exercises/nucleotide-count/README.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
Given a single stranded DNA string, compute how many times each nucleotide occurs in the string.
44

5-
The genetic language of every living thing on the planet is DNA.
6-
DNA is a large molecule that is built from an extremely long sequence of individual elements called nucleotides.
5+
The genetic language of every living thing on the planet is DNA.
6+
DNA is a large molecule that is built from an extremely long sequence of individual elements called nucleotides.
77
4 types exist in DNA and these differ only slightly and can be represented as the following symbols: 'A' for adenine, 'C' for cytosine, 'G' for guanine, and 'T' thymine.
88

99
Here is an analogy:

‎exercises/palindrome-products/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Given a range of numbers, find the largest and smallest palindromes which
99
are products of numbers within that range.
1010

1111
Your solution should return the largest and smallest palindromes, along with the
12-
factors of each within the range. If the largest or smallest palindrome has more
12+
factors of each within the range. If the largest or smallest palindrome has more
1313
than one pair of factors within the range, then return all the pairs.
1414

1515
## Example 1

‎exercises/parallel-letter-frequency/README.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ Single-threaded (non-concurrent) solutions can pass all tests [but the last.](ht
1313

1414
Java documentation on [parallel streams](https://docs.oracle.com/javase/tutorial/collections/streams/parallelism.html) may provide some help.
1515

16+
1617
# Running the tests
1718

1819
You can run all the tests for an exercise by entering
@@ -23,6 +24,7 @@ $ gradle test
2324

2425
in your terminal.
2526

27+
2628
## Submitting Incomplete Solutions
2729

2830
It's possible to submit an incomplete solution so you can see how others have completed the exercise.

‎exercises/pig-latin/README.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ The new error should tell you which type it's expecting.
7878

7979
After having resolved these errors you should be ready to start making the tests pass!
8080

81+
8182
# Running the tests
8283

8384
You can run all the tests for an exercise by entering

‎exercises/protein-translation/README.md‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
#Translate RNA sequences into proteins.
1+
# Protein Translation
2+
3+
Translate RNA sequences into proteins.
24

35
RNA can be broken into three nucleotide sequences called codons, and then translated to a polypeptide like so:
46

@@ -55,4 +57,4 @@ Tyler Long
5557

5658
## Submitting Incomplete Solutions
5759

58-
It's possible to submit an incomplete solution so you can see how others have completed the exercise.
60+
It's possible to submit an incomplete solution so you can see how others have completed the exercise.

0 commit comments

Comments
 (0)