Browse Source

general clarifications and grammar improvements

pull/795/head
Chris 3 years ago
parent
commit
3f818afaef
  1. 4
      subjects/chunk/README.md
  2. 2
      subjects/foldint/README.md
  3. 6
      subjects/grouping/README.md
  4. 2
      subjects/itoabase/README.md
  5. 2
      subjects/piglatin/README.md
  6. 2
      subjects/reduceint/README.md
  7. 2
      subjects/revwstr/README.md
  8. 2
      subjects/slice/README.md
  9. 2
      subjects/union/README.md

4
subjects/chunk/README.md

@ -2,9 +2,9 @@
### Instructions
Write a function called `Chunk` that receives as parameters a slice, `slice []int`, and an number `size int`. The goal of this function is to chunk a slice into many sub slices where each sub slice has the length of `size`.
Write a function called `Chunk` that receives as parameters a slice, `slice []int`, and a number `size int`. The goal of this function is to chunk a slice into many sub slices where each sub slice has the length of `size`.
- If the `size` is `0` it should print `\n`
- If the `size` is `0` it should print a newline (`'\n'`).
### Expected function

2
subjects/foldint/README.md

@ -2,7 +2,7 @@
### Instructions
The function should have as parameters a function, `f func(int, int) int` a slice of integers, `slice []int` and an int `acc int`. You should apply for each element of the slice the arithmetic function, saving and printing it. The function will be tested with our own functions `Add, Sub, and Mul`.
The function should have as parameters a function, `f func(int, int) int` a slice of integers, `slice []int` and an int `acc int`. For each element of the slice, it should apply the arithmetic function, save the result and print it. The function will be tested with our own functions `Add, Sub, and Mul`.
### Expected function

6
subjects/grouping/README.md

@ -4,11 +4,11 @@
Write a program that receives two strings and replicates the use of brackets in regular expressions. Brackets in regular expressions returns the words that contain the expression inside of it.
The program should handle the "`|`" operator, that searches for both strings on each side of the operator.
The program should handle the "`|`" operator, which searches for both strings on each side of the operator.
The output of the program should be the results of the regular expression by order of appearance in the string, being themselves identified by a number.
The output of the program should be, the results of the regular expression, numbered and displayed by the order of appearance in the string.
If the number of arguments is different from 2, if the regular expression is not valid, if the last argument is empty or there are no matches the program should print nothing.
If the number of arguments is different from 2, if the regular expression is not valid, if the last argument is empty or if there are no matches, the program should print nothing.
### Usage

2
subjects/itoabase/README.md

@ -12,7 +12,7 @@ the base are the digits from 0 to 9, followed by uppercase letters from A to F.
For example, the base `4` would be the equivalent of "0123" and the base `16` would be the equivalent of "0123456789ABCDEF".
If the value is negative, the resulting `string` has to be preceded with a
If the value is negative, the resulting `string` has to be preceded by a
minus sign `-`.
Only valid inputs will be tested.

2
subjects/piglatin/README.md

@ -9,7 +9,7 @@ The rules used by Pig Latin are as follows:
- If a word begins with a vowel, just add "ay" to the end.
- If it begins with a consonant, then we take all consonants before the first vowel and we put them on the end of the word and add "ay" at the end.
If the word has no vowels the program should print "No vowels".
If the word has no vowels, the program should print "No vowels".
If the number of arguments is different from one, the program prints nothing.

2
subjects/reduceint/README.md

@ -2,7 +2,7 @@
### Instructions
The function should have as parameters a slice of integers, `a []int` and a function `f func(int, int) int`. You should apply for each element of the slice the arithmetic function, saving it and printing.
The function should have as parameters a slice of integers `a []int` and a function `f func(int, int) int`. For each element of the slice, it should apply the function `f func(int, int) int`, save the result and then print it.
### Expected function

2
subjects/revwstr/README.md

@ -2,7 +2,7 @@
### Instructions
Write a program that takes a `string` as a parameter, and prints its words in reverse.
Write a program that takes a `string` as a parameter, and prints its words in reverse, followed by a newline.
- A word is a sequence of **alphanumerical** characters.

2
subjects/slice/README.md

@ -6,7 +6,7 @@ The function receives a slice of strings and one or more integers, and returns a
In case there only exists one int, the resulting slice begins in the position indicated by the int and ends at the end of the received slice.
The integers can be lower than 0.
The integers can be negative.
### Expected function

2
subjects/union/README.md

@ -4,7 +4,7 @@
Write a program that takes two `string` and displays, without doubles, the characters that appear in either one of the `string`.
The display will be in the order that the characters will appear on the command line and will be followed by a newline (`'\n'`).
The display will be in the same order that the characters appear on the command line and will be followed by a newline (`'\n'`).
If the number of arguments is different from 2, then the program displays a newline (`'\n'`).

Loading…
Cancel
Save