From 4fd2fd5ba320e0641e98f506f698f106b9b7f393 Mon Sep 17 00:00:00 2001 From: "Capt. Cutlass" <5120290+ParanoidUser@users.noreply.github.com> Date: Sun, 28 Jan 2024 16:16:45 -0500 Subject: [PATCH] style: fix code inspection findings (#508) docs: update kata progress --- kata/4-kyu/connect-four-1/README.md | 2 - kata/4-kyu/snail/README.md | 8 +- .../a-man-and-his-umbrellas/main/Weather.java | 2 +- .../README.md | 2 +- kata/5-kyu/gap-in-primes/README.md | 2 +- kata/5-kyu/josephus-permutation/README.md | 2 +- kata/5-kyu/josephus-survivor/README.md | 2 +- .../number-of-trailing-zeros-of-n/README.md | 2 +- .../README.md | 2 +- kata/5-kyu/rot13/README.md | 2 +- .../README.md | 2 +- .../README.md | 2 +- .../README.md | 9 +- kata/6-kyu/disease-spread/README.md | 2 +- kata/6-kyu/easy-diagonal/README.md | 4 +- .../README.md | 87 ++++++++++++++----- kata/6-kyu/feed-kahumolings/README.md | 8 +- .../README.md | 2 +- .../get-the-excel-column-title/README.md | 4 +- kata/6-kyu/html-complementary-color/README.md | 4 +- kata/6-kyu/index.md | 2 +- kata/6-kyu/matrix-multiplier/README.md | 4 +- kata/6-kyu/merge-in-2048/README.md | 2 +- kata/6-kyu/parabolic-arc-length/README.md | 2 +- kata/6-kyu/pascals-triangle/README.md | 6 +- kata/6-kyu/paths-in-the-grid/README.md | 3 - kata/6-kyu/pi-approximation/README.md | 2 +- kata/6-kyu/points-in-the-circle/README.md | 2 +- .../polybius-square-cipher-encode/README.md | 2 +- kata/6-kyu/rainfall/README.md | 4 +- .../README.md | 2 +- kata/6-kyu/roman-numerals-encoder/README.md | 2 +- .../README.md | 2 +- .../README.md | 31 ++++--- kata/6-kyu/steps-in-primes/README.md | 4 +- kata/6-kyu/sudoku-board-validator/README.md | 2 +- kata/6-kyu/tank-truck/README.md | 2 +- .../README.md | 6 +- .../validate-credit-card-number/README.md | 2 +- .../wind-component-calculation/README.md | 2 +- .../README.md | 2 +- .../test/AntiVirusTest.java | 14 ++- kata/7-kyu/arithmetic-sequence/README.md | 2 +- kata/7-kyu/basic-sequence-practice/README.md | 4 +- .../basics-generators-number-1/README.md | 2 +- .../README.md | 4 +- .../7-kyu/collatz-conjecture-length/README.md | 2 +- kata/7-kyu/complementary-dna/README.md | 2 +- kata/7-kyu/easy-line/README.md | 4 +- .../folding-your-way-to-the-moon/README.md | 2 +- kata/7-kyu/herding-cats/README.md | 6 +- .../hungarian-vowel-harmony-easy/README.md | 2 +- .../README.md | 2 +- .../README.md | 2 +- .../README.md | 2 +- .../n-dimensional-vector-magnitude/README.md | 2 +- .../README.md | 2 +- kata/7-kyu/red-knight/README.md | 2 +- .../README.md | 2 +- kata/7-kyu/triangles-from-dots/README.md | 2 +- .../8kyu-interpreters-hq9-plus/README.md | 2 +- .../README.md | 2 +- kata/8-kyu/area-of-a-square/README.md | 4 +- .../test/GodTest.java | 6 +- kata/8-kyu/cat-years-dog-years/README.md | 8 +- .../convert-a-string-to-a-number/README.md | 2 +- .../get-character-from-ascii-value/README.md | 2 +- .../test/KataTests.java | 15 +++- .../README.md | 9 +- kata/8-kyu/rock-paper-scissors/README.md | 2 +- kata/beta/letter-to-ascii/README.md | 2 +- .../README.md | 5 +- kata/beta/tug-o-war/README.md | 2 +- .../bad-hash-string-to-string/README.md | 2 +- .../positive-and-negative-regex/README.md | 2 +- .../sudoku-solution-validator/README.md | 2 +- .../README.md | 2 +- .../vasya-and-system-of-equations/README.md | 2 +- 78 files changed, 205 insertions(+), 162 deletions(-) diff --git a/kata/4-kyu/connect-four-1/README.md b/kata/4-kyu/connect-four-1/README.md index 4e2cbcc8a..3ea0c5a0a 100644 --- a/kata/4-kyu/connect-four-1/README.md +++ b/kata/4-kyu/connect-four-1/README.md @@ -8,8 +8,6 @@ The grid is 6 row by 7 columns, those being named from A to G. You will receive a list of strings showing the order of the pieces which dropped in columns: -![alt text](http://crowd-multilogue.com/Images/Codewars/KataConnectFourWinner.jpg) - ``` piecesPositionList = ["A_Red", "B_Yellow", diff --git a/kata/4-kyu/snail/README.md b/kata/4-kyu/snail/README.md index f7455dff0..b18ae1ee8 100644 --- a/kata/4-kyu/snail/README.md +++ b/kata/4-kyu/snail/README.md @@ -20,7 +20,13 @@ snail(array) #=> [1,2,3,4,5,6,7,8,9] This image will illustrate things more clearly: -![](http://www.haan.lu/files/2513/8347/2456/snail.png) + + + + + + + NOTE: The idea is not sort the elements from the lowest value to the highest; the idea is to traverse the 2-d array in a clockwise snailshell pattern. diff --git a/kata/5-kyu/a-man-and-his-umbrellas/main/Weather.java b/kata/5-kyu/a-man-and-his-umbrellas/main/Weather.java index 3db9b0349..675d47c45 100644 --- a/kata/5-kyu/a-man-and-his-umbrellas/main/Weather.java +++ b/kata/5-kyu/a-man-and-his-umbrellas/main/Weather.java @@ -1,3 +1,3 @@ enum Weather { - CLEAR, SUNNY, CLOUDY, RAINY, OVERCAST, WINDY, THUNDERSTORMS; + CLEAR, SUNNY, CLOUDY, RAINY, OVERCAST, WINDY, THUNDERSTORMS } \ No newline at end of file diff --git a/kata/5-kyu/airport-arrivals-slash-departures-number-1/README.md b/kata/5-kyu/airport-arrivals-slash-departures-number-1/README.md index 222328add..79f56be2e 100644 --- a/kata/5-kyu/airport-arrivals-slash-departures-number-1/README.md +++ b/kata/5-kyu/airport-arrivals-slash-departures-number-1/README.md @@ -2,7 +2,7 @@ You are at the airport staring blankly at the arrivals/departures flap display... -![](http://www.airport-arrivals-departures.com/img/meta/1200_630_arrivals-departures.png) +![](https://www.airport-arrivals-departures.com/img/meta/1200_630_arrivals-departures.png) ## How it works diff --git a/kata/5-kyu/gap-in-primes/README.md b/kata/5-kyu/gap-in-primes/README.md index e41400666..dd8c47aee 100644 --- a/kata/5-kyu/gap-in-primes/README.md +++ b/kata/5-kyu/gap-in-primes/README.md @@ -6,7 +6,7 @@ Between 2 and 50 we have the following pairs of 2-gaps primes: `3-5, 5-7, 11-13, 17-19, 29-31, 41-43` A prime gap of length n is a run of n-1 consecutive composite numbers between two **successive** primes ( -see: http://mathworld.wolfram.com/PrimeGaps.html). +see: https://mathworld.wolfram.com/PrimeGaps.html). We will write a function gap with parameters: diff --git a/kata/5-kyu/josephus-permutation/README.md b/kata/5-kyu/josephus-permutation/README.md index 105250510..029877e38 100644 --- a/kata/5-kyu/josephus-permutation/README.md +++ b/kata/5-kyu/josephus-permutation/README.md @@ -35,5 +35,5 @@ So our final result is: [3,6,2,7,5,1,4] ``` -For more info, browse the Josephus +For more info, browse the Josephus Permutation page on wikipedia; Also, [live game demo](https://iguacel.github.io/josephus/) \ No newline at end of file diff --git a/kata/5-kyu/josephus-survivor/README.md b/kata/5-kyu/josephus-survivor/README.md index 7c4765744..2fa83abff 100644 --- a/kata/5-kyu/josephus-survivor/README.md +++ b/kata/5-kyu/josephus-survivor/README.md @@ -1,7 +1,7 @@ # [Josephus Survivor](https://www.codewars.com/kata/josephus-survivor "https://www.codewars.com/kata/555624b601231dc7a400017a") In this kata you have to correctly return who is the "survivor", ie: the last element of -a Josephus +a Josephus permutation. Basically you have to assume that n people are put into a circle and that they are eliminated in steps of k elements, diff --git a/kata/5-kyu/number-of-trailing-zeros-of-n/README.md b/kata/5-kyu/number-of-trailing-zeros-of-n/README.md index 671ecfb08..2c4504a18 100644 --- a/kata/5-kyu/number-of-trailing-zeros-of-n/README.md +++ b/kata/5-kyu/number-of-trailing-zeros-of-n/README.md @@ -6,7 +6,7 @@ Write a program that will calculate the number of trailing zeros in a factorial Be careful `1000!` has 2568 digits... -For more info, see: http://mathworld.wolfram.com/Factorial.html +For more info, see: https://mathworld.wolfram.com/Factorial.html ## Examples diff --git a/kata/5-kyu/perimeter-of-squares-in-a-rectangle/README.md b/kata/5-kyu/perimeter-of-squares-in-a-rectangle/README.md index 90229f11a..86a49f60c 100644 --- a/kata/5-kyu/perimeter-of-squares-in-a-rectangle/README.md +++ b/kata/5-kyu/perimeter-of-squares-in-a-rectangle/README.md @@ -7,7 +7,7 @@ It's easy to see that the sum of the perimeters of these squares is : Could you give the sum of the perimeters of all the squares in a rectangle when there are n + 1 squares disposed in the same manner as in the drawing: -![alternative text](http://i.imgur.com/EYcuB1wm.jpg) +![alternative text](https://i.imgur.com/EYcuB1wm.jpg) The function perimeter has for parameter n where n + 1 is the number of squares (they are numbered from 0 to n) and returns the total perimeter of all the squares. diff --git a/kata/5-kyu/rot13/README.md b/kata/5-kyu/rot13/README.md index 3db84cb5a..8381090b6 100644 --- a/kata/5-kyu/rot13/README.md +++ b/kata/5-kyu/rot13/README.md @@ -5,7 +5,7 @@ introvert at NSA? Va gur ryringbef, gur rkgebireg ybbxf ng gur BGURE thl'f fubrf. I found this joke on USENET, but the punchline is scrambled. Maybe you can decipher it? -According to Wikipedia, ROT13 (http://en.wikipedia.org/wiki/ROT13) is frequently used to obfuscate +According to Wikipedia, ROT13 (https://en.wikipedia.org/wiki/ROT13) is frequently used to obfuscate jokes on USENET. Hint: For this task you're only supposed to substitue characters. Not spaces, punctuation, numbers diff --git a/kata/6-kyu/all-star-code-challenge-number-15/README.md b/kata/6-kyu/all-star-code-challenge-number-15/README.md index fbe3f6e5d..712a61862 100644 --- a/kata/6-kyu/all-star-code-challenge-number-15/README.md +++ b/kata/6-kyu/all-star-code-challenge-number-15/README.md @@ -3,7 +3,7 @@ **This Kata is intended as a small challenge for my students** Your family runs a shop and have just brought a Scrolling Text -Machine (http://3.imimg.com/data3/RP/IP/MY-2369478/l-e-d-multicolour-text-board-250x250.jpg) to help get some more +Machine (https://3.imimg.com/data3/RP/IP/MY-2369478/l-e-d-multicolour-text-board-250x250.jpg) to help get some more business. The scroller works by replacing the current text string with a similar text string, but with the first letter shifted to diff --git a/kata/6-kyu/convert-integer-to-whitespace-format/README.md b/kata/6-kyu/convert-integer-to-whitespace-format/README.md index 388870d4c..96f2fc0b0 100644 --- a/kata/6-kyu/convert-integer-to-whitespace-format/README.md +++ b/kata/6-kyu/convert-integer-to-whitespace-format/README.md @@ -2,7 +2,7 @@ Hereinafter, `[space]` refers to `" "`, `[tab]` refers to `"\t"`, and `[LF]` refers to `"\n"` for illustrative purposes. This does not mean that you can use these placeholders in your solution. -In esoteric language called [Whitespace](http://compsoc.dur.ac.uk/whitespace/), numbers are represented in the following format: +In esoteric language called [Whitespace](https://esolangs.org/wiki/whitespace), numbers are represented in the following format: * first character represents the sign: `[space]` for plus, `[tab]` for minus; * characters after that and until `[LF]` are the binary representation of the integer: `[space]` for 0, `[tab]` for 1. diff --git a/kata/6-kyu/data-compression-using-run-length-encoding/README.md b/kata/6-kyu/data-compression-using-run-length-encoding/README.md index e5005868b..37943c413 100644 --- a/kata/6-kyu/data-compression-using-run-length-encoding/README.md +++ b/kata/6-kyu/data-compression-using-run-length-encoding/README.md @@ -1,7 +1,10 @@ # [Data compression using run-length encoding](https://www.codewars.com/kata/data-compression-using-run-length-encoding "https://www.codewars.com/kata/578bf2d8daa01a4ee8000046") -[Run-length encoding](http://en.wikipedia.org/wiki/Run-length_encoding) (RLE) is a very simple form of lossless data compression in which runs of data are stored as a single data value and count. +[Run-length encoding](https://en.wikipedia.org/wiki/Run-length_encoding) (RLE) is a very simple form of lossless data +compression in which runs of data are stored as a single data value and count. -A simple form of RLE would encode the string `"AAABBBCCCD"` as `"3A3B3C1D"` meaning, first there are `3 A`, then `3 B`, then `3 C` and last there is `1 D`. +A simple form of RLE would encode the string `"AAABBBCCCD"` as `"3A3B3C1D"` meaning, first there are `3 A`, then `3 B`, +then `3 C` and last there is `1 D`. -Your task is to write a RLE encoder and decoder using this technique. The texts to encode will always consist of only uppercase characters, no numbers. \ No newline at end of file +Your task is to write a RLE encoder and decoder using this technique. The texts to encode will always consist of only +uppercase characters, no numbers. \ No newline at end of file diff --git a/kata/6-kyu/disease-spread/README.md b/kata/6-kyu/disease-spread/README.md index 5551d6b3d..22e14c494 100644 --- a/kata/6-kyu/disease-spread/README.md +++ b/kata/6-kyu/disease-spread/README.md @@ -53,4 +53,4 @@ epidemic(tm, n, s0, i0, b, a) --> 483 - Keeping track of the values of susceptible, infected and recovered you can plot the solutions of the 3 differential equations. See an example below on the plot. -![alternative text](http://i.imgur.com/xB6VSqzm.png) +![alternative text](https://i.imgur.com/xB6VSqzm.png) \ No newline at end of file diff --git a/kata/6-kyu/easy-diagonal/README.md b/kata/6-kyu/easy-diagonal/README.md index 5d54640d2..16c080db8 100644 --- a/kata/6-kyu/easy-diagonal/README.md +++ b/kata/6-kyu/easy-diagonal/README.md @@ -23,6 +23,6 @@ diagonal(20, 4) => 20349 When following a diagonal from top to bottom have a look at the numbers on the diagonal at its right. ## Ref: -http://mathworld.wolfram.com/BinomialCoefficient.html +https://mathworld.wolfram.com/BinomialCoefficient.html -![alternative text](http://i.imgur.com/eUGaNvIm.jpg) \ No newline at end of file +![alternative text](https://i.imgur.com/eUGaNvIm.jpg) \ No newline at end of file diff --git a/kata/6-kyu/esolang-interpreters-number-1-introduction-to-esolangs-and-my-first-interpreter-ministringfuck/README.md b/kata/6-kyu/esolang-interpreters-number-1-introduction-to-esolangs-and-my-first-interpreter-ministringfuck/README.md index fc8cfd7e8..05839c7db 100644 --- a/kata/6-kyu/esolang-interpreters-number-1-introduction-to-esolangs-and-my-first-interpreter-ministringfuck/README.md +++ b/kata/6-kyu/esolang-interpreters-number-1-introduction-to-esolangs-and-my-first-interpreter-ministringfuck/README.md @@ -1,28 +1,54 @@ # [Esolang Interpreters #1 - Introduction to Esolangs and My First Interpreter (MiniStringFuck)](https://www.codewars.com/kata/esolang-interpreters-number-1-introduction-to-esolangs-and-my-first-interpreter-ministringfuck "https://www.codewars.com/kata/586dd26a69b6fd46dd0000c0") -An [esoteric programming language](http://esolangs.org), otherwise known as an **Esolang**, is an informal computer programming language that is generally not designed for serious practical use. There are a few main aims/themes among the vast majority of such languages: - -1. **Achieve Turing-completeness in as few commands (instructions) as possible.** There are currently a number of implemented Esolangs that have been proven to be Turing-complete, [Brainfuck](http://esolangs.org/wiki/Brainfuck) being the most popular of them all, comprised of no more than 8 distinct commands. Despite having only 8 commands, it has been [objectively proven to be Turing-complete](http://www.hevanet.com/cristofd/brainfuck/utm.b). However, Brainfuck is not the Turing-complete programming language with the fewest commands. [Boolfuck](http://esolangs.org/wiki/Boolfuck), a derivative of Brainfuck which operates on bits (`0`s and `1`s) and contains **7 commands** only, has also been proven to be Turing-complete through reduction from Brainfuck. Another less-known Esolang called [Etre](http://codewars.com/wiki/Etre) contains as few as **3 commands** yet has been proven to be Turing-complete through the translation of a Minsky Machine to Etre. -2. **To be as hard to program in as possible.** The famous [Brainfuck](http://esolangs.org/wiki/Brainfuck) Esolang is well known as a **Turing tarpit** - that is, a Turing-complete programming language where it is very hard to write a useful program in reality. However, Brainfuck is most definitely not the hardest Esolang to program in. For example, its close cousin, Boolfuck, which operates on bits (mentioned above) is even harder to program in. There have also been a small number of implemented Esolangs which are so difficult to program in that no one has ever successfully written a single program in it from scratch - the only programs generated from these languages came from computers! -3. **As a joke.** Many Esolangs out there have been invented solely as a joke. Examples include [Ook!](http://esolangs.org/wiki/Ook!) and [Bitxtreme](http://esolangs.org/wiki/bitxtreme). - -Although there is no clear-cut definition as to when a programming language is esoteric (or not), Esolangs can generally be identified by the following features/traits: +An [esoteric programming language](https://esolangs.org/wiki/Main_Page), otherwise known as an **Esolang**, is an +informal computer programming language that is generally not designed for serious practical use. There are a few main +aims/themes among the vast majority of such languages: + +1. **Achieve Turing-completeness in as few commands (instructions) as possible.** There are currently a number of + implemented Esolangs that have been proven to be Turing-complete, [Brainfuck](https://esolangs.org/wiki/Brainfuck) + being the most popular of them all, comprised of no more than 8 distinct commands. Despite having only 8 commands, it + has been [objectively proven to be Turing-complete](https://brainfuck.org/utm.b). However, Brainfuck is not the + Turing-complete programming language with the fewest commands. [Boolfuck](https://esolangs.org/wiki/Boolfuck), a + derivative of Brainfuck which operates on bits (`0`s and `1`s) and contains **7 commands** only, has also been proven + to be Turing-complete through reduction from Brainfuck. Another less-known Esolang + called [Etre](https://esolangs.org/wiki/Etre) contains as few as **3 commands** yet has been proven to be + Turing-complete through the translation of a Minsky Machine to Etre. +2. **To be as hard to program in as possible.** The famous [Brainfuck](https://esolangs.org/wiki/Brainfuck) Esolang is + well known as a **Turing tarpit** - that is, a Turing-complete programming language where it is very hard to write a + useful program in reality. However, Brainfuck is most definitely not the hardest Esolang to program in. For example, + its close cousin, Boolfuck, which operates on bits (mentioned above) is even harder to program in. There have also + been a small number of implemented Esolangs which are so difficult to program in that no one has ever successfully + written a single program in it from scratch - the only programs generated from these languages came from computers! +3. **As a joke.** Many Esolangs out there have been invented solely as a joke. Examples + include [Ook!](https://esolangs.org/wiki/Ook!) and [Bitxtreme](https://esolangs.org/wiki/bitxtreme). + +Although there is no clear-cut definition as to when a programming language is esoteric (or not), Esolangs can generally +be identified by the following features/traits: 1. Minimalistic - having as few instructions as possible -2. Plays with new concepts - for example, [Befunge](http://esolangs.org/wiki/Befunge), another very popular Esolang, is interpreted in **two dimensions** as opposed to the usual linear way of interpreting code -3. Themed - this is a trait of many joke Esolangs. For example, some may be fashioned like Shakespearean plays and others like cooking recipes -4. Not clearly documented - Many Esolangs out there have not been described in great detail with perhaps only a few code examples on the entire Internet. Some Esolangs have not even been implemented yet! -5. Contain incomplete specs - New Esolangs are being invented every day. Some Esolangs on the Internet are still a work-in-progress and their commands and behaviour have not been finalised yet. - -Nevertheless, Esolangs are generally fun to program in, experiment with and write interpreters for. A great deal can be learned about certain concepts and theories in Computer Science just by studying and programming in a well-designed Esolang such as Brainfuck or Befunge. +2. Plays with new concepts - for example, [Befunge](https://esolangs.org/wiki/Befunge), another very popular Esolang, is + interpreted in **two dimensions** as opposed to the usual linear way of interpreting code +3. Themed - this is a trait of many joke Esolangs. For example, some may be fashioned like Shakespearean plays and + others like cooking recipes +4. Not clearly documented - Many Esolangs out there have not been described in great detail with perhaps only a few code + examples on the entire Internet. Some Esolangs have not even been implemented yet! +5. Contain incomplete specs - New Esolangs are being invented every day. Some Esolangs on the Internet are still a + work-in-progress and their commands and behaviour have not been finalised yet. + +Nevertheless, Esolangs are generally fun to program in, experiment with and write interpreters for. A great deal can be +learned about certain concepts and theories in Computer Science just by studying and programming in a well-designed +Esolang such as Brainfuck or Befunge. Next off, I will introduce you to a simple, minimalistic Esolang called **MiniStringFuck**. ## The Language -[MiniStringFuck](http://esolangs.org/wiki/MiniStringFuck) is a derivative of the famous [Brainfuck](http://esolangs.org/wiki/Brainfuck) which contains a **memory cell** as its only form of data storage as opposed to a memory tape of 30,000 cells in Brainfuck. The **memory cell** in MiniStringFuck initially starts at `0`. MiniStringFuck contains only 2 commands as opposed to 8: +[MiniStringFuck](https://esolangs.org/wiki/MiniStringFuck) is a derivative of the +famous [Brainfuck](https://esolangs.org/wiki/Brainfuck) which contains a **memory cell** as its only form of data +storage as opposed to a memory tape of 30,000 cells in Brainfuck. The **memory cell** in MiniStringFuck initially starts +at `0`. MiniStringFuck contains only 2 commands as opposed to 8: -- `+` - Increment the memory cell. If it reaches `256`, wrap to `0`. +- `+` - Increment the memory cell. If it reaches `256`, wrap to `0`. - `.` - Output the ASCII value of the memory cell For example, here is a MiniStringFuck program that outputs the string `"Hello, World!"`: @@ -37,21 +63,34 @@ And here is another program that prints the uppercase English alphabet: +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+.+. ``` -Any characters in a MiniStringFuck program other than `+` or `.` are simply non-command characters (no-ops, i.e. do nothing) and therefore can serve as comments in the program. +Any characters in a MiniStringFuck program other than `+` or `.` are simply non-command characters (no-ops, i.e. do +nothing) and therefore can serve as comments in the program. ## The Task Time to write your first Esolang interpreter :D -Your task is to implement a MiniStringFuck interpreter `myFirstInterpreter()`/`my_first_interpreter()`/`Interpreter()`/`interpret()` (depending on your language) which accepts exactly 1 required argument `code`/`$code` which is the MiniStringFuck program to be executed. The output of the program should then be returned by your interpreter as a string. +Your task is to implement a MiniStringFuck +interpreter `myFirstInterpreter()`/`my_first_interpreter()`/`Interpreter()`/`interpret()` (depending on your language) +which accepts exactly 1 required argument `code`/`$code` which is the MiniStringFuck program to be executed. The output +of the program should then be returned by your interpreter as a string. -For Java you'll implement the `MyFirstInterpreter` class which accepts 1 String in it's constructor and returns the output from the `interpret` method. +For Java you'll implement the `MyFirstInterpreter` class which accepts 1 String in it's constructor and returns the +output from the `interpret` method. Since this is the first time you are about to write an interpreter for an Esolang, here are a few quick tips: -- If you are afraid that your interpreter will be confused by non-command characters appearing in the MiniStringFuck program, you can try to remove all non-command characters from the `code` input before letting your interpreter interpret it -- The memory cell in MiniStringFuck only ever contains a single integer value - think of how it can be modelled in your interpreter -- If you are stuck as to how to interpret the string as a program, try thinking of strings as an array of characters. Try looping through the "program" like you would an array -- Writing an interpreter for an Esolang can sometimes be quite confusing! It never hurts to add a few comments in your interpreter as you implement it to remind yourself of what is happening within the interpreter at every stage - -*NOTE: If you would not like to name your interpreter as* `myFirstInterpreter()`/`my_first_interpreter()`*, you can optionally rename it to either* `miniStringFuck()`/`mini_string_fuck()` *or* `interpreter()` *instead - the test cases will handle the rest for you.* **Not available in Java, Go, Swift, TypeScript, Haskell, Elixir, C++, C#, Rust, R, Erlang, F# and NASM**; *irrelevant to Brainfuck solvers* ;) \ No newline at end of file +- If you are afraid that your interpreter will be confused by non-command characters appearing in the MiniStringFuck + program, you can try to remove all non-command characters from the `code` input before letting your interpreter + interpret it +- The memory cell in MiniStringFuck only ever contains a single integer value - think of how it can be modelled in your + interpreter +- If you are stuck as to how to interpret the string as a program, try thinking of strings as an array of characters. + Try looping through the "program" like you would an array +- Writing an interpreter for an Esolang can sometimes be quite confusing! It never hurts to add a few comments in your + interpreter as you implement it to remind yourself of what is happening within the interpreter at every stage + +*NOTE: If you would not like to name your interpreter as* `myFirstInterpreter()`/`my_first_interpreter()`*, you can +optionally rename it to either* `miniStringFuck()`/`mini_string_fuck()` *or* `interpreter()` *instead - the test cases +will handle the rest for you.* **Not available in Java, Go, Swift, TypeScript, Haskell, Elixir, C++, C#, Rust, R, +Erlang, F# and NASM**; *irrelevant to Brainfuck solvers* ;) \ No newline at end of file diff --git a/kata/6-kyu/feed-kahumolings/README.md b/kata/6-kyu/feed-kahumolings/README.md index 0f2bbe756..2c3a65b1b 100644 --- a/kata/6-kyu/feed-kahumolings/README.md +++ b/kata/6-kyu/feed-kahumolings/README.md @@ -1,11 +1,5 @@ # [Feed Kahumolings!](https://www.codewars.com/kata/feed-kahumolings "https://www.codewars.com/kata/557b75579b03996942000061") -
- -![Alien mouths](http://vignette3.wikia.nocookie.net/ben10/images/e/e4/Ben10mouthoff_lrg.jpg) - -
- You are a cook in an alien restaurant at a distant planet called Kahumo. These aliens have some specific physiology features: @@ -39,4 +33,4 @@ Kahumolings have very sensitive tongues, but not absolutely sensitive. They can serve(31, 2, 5) returns {1.0, 2.0, 4.0, 8.0, 16.0} serve(728, 3, 6) returns {2.0, 6.0, 18.0, 54.0, 162.0, 486.0} serve(100, 1.5, 3) returns {21.053, 31.579, 47.368} -``` +``` \ No newline at end of file diff --git a/kata/6-kyu/fibonacci-tribonacci-and-friends/README.md b/kata/6-kyu/fibonacci-tribonacci-and-friends/README.md index 94930d9e9..bffdd242e 100644 --- a/kata/6-kyu/fibonacci-tribonacci-and-friends/README.md +++ b/kata/6-kyu/fibonacci-tribonacci-and-friends/README.md @@ -1,6 +1,6 @@ # [Fibonacci, Tribonacci and friends](https://www.codewars.com/kata/fibonacci-tribonacci-and-friends "https://www.codewars.com/kata/556e0fccc392c527f20000c5") -If you have completed the Tribonacci sequence kata, you would know by now that mister Fibonacci has at least a bigger brother. If not, give it a quick look to get how things work. +If you have completed the Tribonacci sequence kata, you would know by now that mister Fibonacci has at least a bigger brother. If not, give it a quick look to get how things work. Well, time to expand the family a little more: think of a Quadribonacci starting with a signature of 4 elements and each following element is the sum of the 4 previous, a Pentabonacci (well *Cinquebonacci* would probably sound a bit more italian, but it would also sound really awful) with a signature of 5 elements and each following element is the sum of the 5 previous, and so on. diff --git a/kata/6-kyu/get-the-excel-column-title/README.md b/kata/6-kyu/get-the-excel-column-title/README.md index a0a996203..5ecd9d525 100644 --- a/kata/6-kyu/get-the-excel-column-title/README.md +++ b/kata/6-kyu/get-the-excel-column-title/README.md @@ -13,8 +13,8 @@ For example, the first column has the title "A", second column - "B", 26th - "Z" "BA"(53) comes after "AZ"(52), "AAA" comes after "ZZ". - - + + Excel? Columns? More details [here](https://en.wikipedia.org/wiki/Microsoft_Excel) diff --git a/kata/6-kyu/html-complementary-color/README.md b/kata/6-kyu/html-complementary-color/README.md index c21262317..52474c2b5 100644 --- a/kata/6-kyu/html-complementary-color/README.md +++ b/kata/6-kyu/html-complementary-color/README.md @@ -6,11 +6,11 @@ You have to implement the or `getReversedColor(hexColor)` (JavaScript, Java) - + function that takes a hex-color string and returns the string represents the complementary color. -What is the hex-color? You can find the answer on [w3schools](http://www.w3schools.com/colors/colors_picker.asp) and [Wikipedia](https://en.wikipedia.org/wiki/Web_colors) +What is the hex-color? You can find the answer on [w3schools](https://www.w3schools.com/colors/colors_picker.asp) and [Wikipedia](https://en.wikipedia.org/wiki/Web_colors) ## Input It takes only one argument - string with hex value (case-ignored with chars 0..9 or A..F) without hash-char "#". diff --git a/kata/6-kyu/index.md b/kata/6-kyu/index.md index 162ba009e..a7767209d 100644 --- a/kata/6-kyu/index.md +++ b/kata/6-kyu/index.md @@ -116,7 +116,7 @@ - [Ease the StockBroker](ease-the-stockbroker) - [Easy Balance Checking](easy-balance-checking) - [Easy Diagonal](easy-diagonal) -- [Emotional Sort ( ︶︿︶)](emotional-sort-<) +- [Emotional Sort ( ︶︿︶)](emotional-sort) - [Encrypt this!](encrypt-this) - [English beggars](english-beggars) - [Enigeliisohe too Eniigeeliiisoohee Toroanisoliatooro](enigeliisohe-too-eniigeeliiisoohee-toroanisoliatooro) diff --git a/kata/6-kyu/matrix-multiplier/README.md b/kata/6-kyu/matrix-multiplier/README.md index 5e2b1cbdb..37d7dafe7 100644 --- a/kata/6-kyu/matrix-multiplier/README.md +++ b/kata/6-kyu/matrix-multiplier/README.md @@ -2,9 +2,9 @@ In mathematics, a matrix ( plural matrices) is a rectangular array of numbers. Matrices have many applications in programming, -from +from performing transformations in 2D space -to machine learning. +to machine learning. One of the most useful operations to perform on matrices is matrix multiplication, which diff --git a/kata/6-kyu/merge-in-2048/README.md b/kata/6-kyu/merge-in-2048/README.md index 59228affb..4af9b8aa3 100644 --- a/kata/6-kyu/merge-in-2048/README.md +++ b/kata/6-kyu/merge-in-2048/README.md @@ -1,6 +1,6 @@ # [Merge in 2048](https://www.codewars.com/kata/merge-in-2048 "https://www.codewars.com/kata/55e1990978c60e5052000011") -Remember the game 2048? http://gabrielecirulli.github.io/2048/ +Remember the game 2048? https://play2048.co The main part of this game is merging identical tiles in a row. diff --git a/kata/6-kyu/parabolic-arc-length/README.md b/kata/6-kyu/parabolic-arc-length/README.md index bab5a4e20..638d3af77 100644 --- a/kata/6-kyu/parabolic-arc-length/README.md +++ b/kata/6-kyu/parabolic-arc-length/README.md @@ -20,4 +20,4 @@ The coordinates of each Pi are (xi, y +- A ref: -- `data` and `data1` (can be named `d0` and `d1` depending on the language; see "Sample Tests:") are adapted from: +- `data` and `data1` (can be named `d0` and `d1` depending on the language; see "Sample Tests:") are adapted from: \ No newline at end of file diff --git a/kata/6-kyu/reverse-polish-notation-calculator/README.md b/kata/6-kyu/reverse-polish-notation-calculator/README.md index c608f4214..384ad6c28 100644 --- a/kata/6-kyu/reverse-polish-notation-calculator/README.md +++ b/kata/6-kyu/reverse-polish-notation-calculator/README.md @@ -1,6 +1,6 @@ # [Reverse polish notation calculator](https://www.codewars.com/kata/reverse-polish-notation-calculator "https://www.codewars.com/kata/52f78966747862fc9a0009ae") -Your job is to create a calculator which evaluates expressions in [Reverse Polish notation](http://en.wikipedia.org/wiki/Reverse_Polish_notation). +Your job is to create a calculator which evaluates expressions in [Reverse Polish notation](https://en.wikipedia.org/wiki/Reverse_Polish_notation). For example expression `5 1 2 + 4 * + 3 -` (which is equivalent to `5 + ((1 + 2) * 4) - 3` in normal notation) should evaluate to `14`. diff --git a/kata/6-kyu/roman-numerals-encoder/README.md b/kata/6-kyu/roman-numerals-encoder/README.md index 634503947..aa770804d 100644 --- a/kata/6-kyu/roman-numerals-encoder/README.md +++ b/kata/6-kyu/roman-numerals-encoder/README.md @@ -23,4 +23,4 @@ M 1,000 Remember that there can't be more than 3 identical symbols in a row. -More about roman numerals - http://en.wikipedia.org/wiki/Roman_numerals \ No newline at end of file +More about roman numerals - https://en.wikipedia.org/wiki/Roman_numerals \ No newline at end of file diff --git a/kata/6-kyu/simple-fun-number-210-maximize-points/README.md b/kata/6-kyu/simple-fun-number-210-maximize-points/README.md index a182941db..284433479 100644 --- a/kata/6-kyu/simple-fun-number-210-maximize-points/README.md +++ b/kata/6-kyu/simple-fun-number-210-maximize-points/README.md @@ -5,7 +5,7 @@ Two teams are playing a game of tennis. The team sizes are the same and each player from the first team plays against the corresponding player from the second team. -![](http://i.imgur.com/YB1dsAm.jpg) +![](https://i.imgur.com/YB1dsAm.jpg) Each player has a certain power level. If a player has a higher power level than her opponent, she is guaranteed to win and her team would get 1 point for that win while the opponents get a 0. diff --git a/kata/6-kyu/simpsons-rule-approximate-integration/README.md b/kata/6-kyu/simpsons-rule-approximate-integration/README.md index a98330281..d333d1bce 100644 --- a/kata/6-kyu/simpsons-rule-approximate-integration/README.md +++ b/kata/6-kyu/simpsons-rule-approximate-integration/README.md @@ -1,29 +1,28 @@ # [Simpson's Rule - Approximate Integration](https://www.codewars.com/kata/simpsons-rule-approximate-integration "https://www.codewars.com/kata/565abd876ed46506d600000d") An integral: - - - +```math +\int_{a}^{b}f(x)dx +``` can be approximated by the so-called Simpson’s rule: - - +```math +\dfrac{b-a}{3n}(f(a)+f(b)+4\sum_{i=1}^{n/2}f(a+(2i-1)h)+2\sum_{i=1}^{n/2-1}f(a+2ih)) +``` +Here +`h = (b - a) / n`, `n` being an even integer and `a <= b`. -Here `h = (b-a)/n`, `n` being an even integer and `a <= b`. We want to try Simpson's rule with the function f: - +```math +f(x) = \frac{3}{2}\sin(x)^3 +``` -The task is to write a function called `simpson` with parameter `n` which returns the value of the integral of f -on the interval - -. +The task is to write a function called `simpson` with parameter `n` which returns the value of the integral of f on the interval `[0, pi]` (pi being 3.14159265359...). -## Notes: +#### Notes: - Don't round or truncate your results. See in "RUN EXAMPLES" the function `assertFuzzyEquals` or `testing`. - `n` will always be even. -- We know that the exact value of the integral of f on the given interval is `2`. \ No newline at end of file +- We know that the exact value of the integral of f on the given interval is `2`. +- Please ask before translating. \ No newline at end of file diff --git a/kata/6-kyu/steps-in-primes/README.md b/kata/6-kyu/steps-in-primes/README.md index 8e0dc4f27..81dfcd24a 100644 --- a/kata/6-kyu/steps-in-primes/README.md +++ b/kata/6-kyu/steps-in-primes/README.md @@ -43,10 +43,10 @@ between the limits `m`, `n` if these g-steps prime numbers exist otherwise `nil` ## Notes: The idea of "step" is close to that of "gap" but it is not exactly the same. For those interested they can have a look -at . +at . A "gap" is more restrictive: there must be no primes in between (101-107 is a "step" but not a "gap". Next kata will be about "gaps":-). For Go: nil slice is expected when there are no `step` between m and n. -Example: step(2,4900,4919) --> nil +Example: step(2,4900,4919) --> nil \ No newline at end of file diff --git a/kata/6-kyu/sudoku-board-validator/README.md b/kata/6-kyu/sudoku-board-validator/README.md index bffa02a7f..21bea19af 100644 --- a/kata/6-kyu/sudoku-board-validator/README.md +++ b/kata/6-kyu/sudoku-board-validator/README.md @@ -5,7 +5,7 @@ Sudoku is a game played on a 9x9 grid. The goal of the game is to fill all cells of the grid with digits from 1 to 9, so that each column, each row, and each of the nine 3x3 sub-grids (also known as blocks) contain all the digits from 1 to 9. -More info at: http://en.wikipedia.org/wiki/Sudoku +More info at: https://en.wikipedia.org/wiki/Sudoku ### Sudoku Solution Validator diff --git a/kata/6-kyu/tank-truck/README.md b/kata/6-kyu/tank-truck/README.md index 5630f08a1..6dc9bf1d4 100644 --- a/kata/6-kyu/tank-truck/README.md +++ b/kata/6-kyu/tank-truck/README.md @@ -26,4 +26,4 @@ tankvol(80,120,3500) should return 2478 (calculation gives about: 2478.73007973) Tank vertical section: -![alternative text](http://i.imgur.com/wmt0U43.png) \ No newline at end of file +![alternative text](https://i.imgur.com/wmt0U43.png) \ No newline at end of file diff --git a/kata/6-kyu/the-enigma-machine-part-1-the-plugboard/README.md b/kata/6-kyu/the-enigma-machine-part-1-the-plugboard/README.md index 193ab2aa5..21e9375e0 100644 --- a/kata/6-kyu/the-enigma-machine-part-1-the-plugboard/README.md +++ b/kata/6-kyu/the-enigma-machine-part-1-the-plugboard/README.md @@ -1,14 +1,14 @@ # [The Enigma Machine - Part 1: The Plugboard](https://www.codewars.com/kata/the-enigma-machine-part-1-the-plugboard "https://www.codewars.com/kata/5523b97ac8f5025c45000900") -In this series of Kata, we will be implementing a software version of the [Enigma Machine](http://en.wikipedia.org/wiki/Enigma_machine). +In this series of Kata, we will be implementing a software version of the [Enigma Machine](https://en.wikipedia.org/wiki/Enigma_machine). -The Enigma Machine was a message enciphering/deciphering machine used during the Second World War for disguising the content of military communications. [Alan Turing](http://en.wikipedia.org/wiki/Alan_Turing) - the father of computing - formulated and developed concepts that are the basis of all computers in use today, he did this in response to the vital need to break those military communications. Turing and his colleagues at [Bletchley Park](http://en.wikipedia.org/wiki/Bletchley_Park) are generally recognised as being responsible for shortening WWII by two years and saving an estimated 22 Million lives. +The Enigma Machine was a message enciphering/deciphering machine used during the Second World War for disguising the content of military communications. [Alan Turing](https://en.wikipedia.org/wiki/Alan_Turing) - the father of computing - formulated and developed concepts that are the basis of all computers in use today, he did this in response to the vital need to break those military communications. Turing and his colleagues at [Bletchley Park](https://en.wikipedia.org/wiki/Bletchley_Park) are generally recognised as being responsible for shortening WWII by two years and saving an estimated 22 Million lives. The Enigma Machine consisted of a number of parts: Keyboard for input, rotors and plugboard for enciphering, and lampboard for output. We will simulate input and output with strings, and build the rotors, plugboard and mechanism that used them in software. As we progress the code will become more complex, so you are advised to attempt them in order. -Step 1: The [plugboard](http://en.wikipedia.org/wiki/Enigma_machine#Plugboard) +Step 1: The [plugboard](https://en.wikipedia.org/wiki/Enigma_machine#Plugboard) In this Kata, you must implement the plugboard. diff --git a/kata/6-kyu/validate-credit-card-number/README.md b/kata/6-kyu/validate-credit-card-number/README.md index c92de9862..75c2acc36 100644 --- a/kata/6-kyu/validate-credit-card-number/README.md +++ b/kata/6-kyu/validate-credit-card-number/README.md @@ -1,6 +1,6 @@ # [Validate Credit Card Number](https://www.codewars.com/kata/validate-credit-card-number "https://www.codewars.com/kata/5418a1dd6d8216e18a0012b2") -In this Kata, you will implement the [Luhn Algorithm](http://en.wikipedia.org/wiki/Luhn_algorithm), which is used to help validate credit card numbers. +In this Kata, you will implement the [Luhn Algorithm](https://en.wikipedia.org/wiki/Luhn_algorithm), which is used to help validate credit card numbers. Given a positive integer of up to 16 digits, return ```true``` if it is a valid credit card number, and ```false``` if it is not. diff --git a/kata/6-kyu/wind-component-calculation/README.md b/kata/6-kyu/wind-component-calculation/README.md index f68d6c798..332d77b3c 100644 --- a/kata/6-kyu/wind-component-calculation/README.md +++ b/kata/6-kyu/wind-component-calculation/README.md @@ -29,4 +29,4 @@ CW = sin(A) * WS HW = cos(A) * WS ``` More information about wind component calculation: -http://en.wikipedia.org/wiki/Tailwind +https://en.wikipedia.org/wiki/Tailwind \ No newline at end of file diff --git a/kata/7-kyu/ad2070-help-lorimar-troubleshoot-his-robots-ultrasonic-distance-analysis/README.md b/kata/7-kyu/ad2070-help-lorimar-troubleshoot-his-robots-ultrasonic-distance-analysis/README.md index 9cb2418d4..c6b074c58 100644 --- a/kata/7-kyu/ad2070-help-lorimar-troubleshoot-his-robots-ultrasonic-distance-analysis/README.md +++ b/kata/7-kyu/ad2070-help-lorimar-troubleshoot-his-robots-ultrasonic-distance-analysis/README.md @@ -19,4 +19,4 @@ Return a tuple with the mean and standard deviation of the distance variables ro (118.6275, 3.5779) ``` -Hint (http://math.stackexchange.com/questions/15098/sample-standard-deviation-vs-population-standard-deviation) \ No newline at end of file +Hint (https://math.stackexchange.com/questions/15098/sample-standard-deviation-vs-population-standard-deviation) \ No newline at end of file diff --git a/kata/7-kyu/anti-virus-file-scanner/test/AntiVirusTest.java b/kata/7-kyu/anti-virus-file-scanner/test/AntiVirusTest.java index bd1f61290..e98fce2b3 100644 --- a/kata/7-kyu/anti-virus-file-scanner/test/AntiVirusTest.java +++ b/kata/7-kyu/anti-virus-file-scanner/test/AntiVirusTest.java @@ -1,15 +1,21 @@ import static org.junit.jupiter.api.Assertions.assertEquals; +import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; class AntiVirusTest { - @Test - void sample() { + private VirusDB db; + + @BeforeEach + void setUp() { var intensity1signatures = new String[]{"malware", "virus", "infect"}; var intensity2signatures = new String[]{"ransomware", "trojan", "trojanHorse", "worm", "spyware", "keystrokelogger", "adware", "botnet", "rootkit"}; var intensity3signatures = new String[]{"DeleteSys32", "OverideMBR", "EncryptAll", "openrandomwebsite", "openrandwebsite", "sendalldata", "recordKeyboard", "recordmouse", "destroy", "overheat", "getfullcontrol", "uploadharddrive", "uploadharddisk", "overload", "changeOS", "encrypt", "changeDesktop", "ddos", "dos", "hide", "inject", "ransom", "getcreditcardinfo", "getpasswords", "getpass"}; - var db = new VirusDB(intensity1signatures, intensity2signatures, intensity3signatures); + db = new VirusDB(intensity1signatures, intensity2signatures, intensity3signatures); + } + @Test + void sample() { var f1 = new File("file0", "qmesMJq1EAjBLPclDJVil3kmP3Bgj5qocZQnQuK0rGffyHvMCY"); var f2 = new File("file1", "1OipRqMWEaZlviruse48XKWO2VLz40YMiC9x7FlUOsjg9"); var f3 = new File("file2", "q4khFPhsPyWareRbxFZefTpN74cRr8Rh9b18Gtvbyz3"); @@ -45,4 +51,4 @@ void sample() { assertEquals("file2 is not safe", av.scanFile(f3, db)); assertEquals("file3 is not safe", av.scanFile(f4, db)); } -} +} \ No newline at end of file diff --git a/kata/7-kyu/arithmetic-sequence/README.md b/kata/7-kyu/arithmetic-sequence/README.md index e3f7fc3b7..dd2e3eba0 100644 --- a/kata/7-kyu/arithmetic-sequence/README.md +++ b/kata/7-kyu/arithmetic-sequence/README.md @@ -6,7 +6,7 @@ An example would be (where the first term is 0 and the constant is 1) is [0, 1, Else if (pun) ``f(n) = f(n-1) * c`` where ``c`` is a constant value, then ``f`` is a geometric sequence.
Example where the first term is 2 and the constant is 2 will be [2, 4, 8, 16, 32, 64, ... to infinity ... ]
There are some sequences that aren't arithmetic nor are they geometric.
-Here is a link to feed your brain : Sequence ! +Here is a link to feed your brain : Sequence ! You're going to write a function that's going to return the value in the nth index of an arithmetic sequence.(That is, adding a constant to move to the next element in the "set"). diff --git a/kata/7-kyu/basic-sequence-practice/README.md b/kata/7-kyu/basic-sequence-practice/README.md index c93fe5a45..1134b884e 100644 --- a/kata/7-kyu/basic-sequence-practice/README.md +++ b/kata/7-kyu/basic-sequence-practice/README.md @@ -1,6 +1,6 @@ # [Basic Sequence Practice](https://www.codewars.com/kata/basic-sequence-practice "https://www.codewars.com/kata/5436f26c4e3d6c40e5000282") -A [sequence or a series](http://world.mathigon.org/Sequences), in mathematics, is a string of objects, like numbers, that follow a particular pattern. The individual elements in a sequence are called terms. A simple example is `3, 6, 9, 12, 15, 18, 21, ...`, where the pattern is: _"add 3 to the previous term"_. +A [sequence or a series](https://mathigon.org/course/sequences/introduction), in mathematics, is a string of objects, like numbers, that follow a particular pattern. The individual elements in a sequence are called terms. A simple example is `3, 6, 9, 12, 15, 18, 21, ...`, where the pattern is: _"add 3 to the previous term"_. In this kata, we will be using a more complicated sequence: `0, 1, 3, 6, 10, 15, 21, 28, ...` This sequence is generated with the pattern: _"the nth term is the sum of numbers from 0 to n, inclusive"_. @@ -20,4 +20,4 @@ Complete the function that takes an integer `n` and returns a list/array of leng 5 --> [0, 1, 3, 6, 10, 15] -5 --> [0, -1, -3, -6, -10, -15] 7 --> [0, 1, 3, 6, 10, 15, 21, 28] -``` +``` \ No newline at end of file diff --git a/kata/7-kyu/basics-generators-number-1/README.md b/kata/7-kyu/basics-generators-number-1/README.md index 2569ba44b..617371ca6 100644 --- a/kata/7-kyu/basics-generators-number-1/README.md +++ b/kata/7-kyu/basics-generators-number-1/README.md @@ -9,4 +9,4 @@ You must complete the generator function that must increment a counter by 1 each

Important

The counter must start at 1 when the generator is initialized -More Info: Iterators and Generators (JavaScript), [Generators Overview (PHP)](http://php.net/manual/en/language.generators.overview.php) \ No newline at end of file +More Info: Iterators and Generators (JavaScript), [Generators Overview (PHP)](https://www.php.net/manual/en/language.generators.overview.php) \ No newline at end of file diff --git a/kata/7-kyu/calculate-the-harmonic-conjugated-point-of-a-triplet-of-aligned-points/README.md b/kata/7-kyu/calculate-the-harmonic-conjugated-point-of-a-triplet-of-aligned-points/README.md index 1ac7041d9..55480dfb8 100644 --- a/kata/7-kyu/calculate-the-harmonic-conjugated-point-of-a-triplet-of-aligned-points/README.md +++ b/kata/7-kyu/calculate-the-harmonic-conjugated-point-of-a-triplet-of-aligned-points/README.md @@ -1,6 +1,6 @@ # [Calculate the Harmonic Conjugated Point of a Triplet of Aligned Points](https://www.codewars.com/kata/calculate-the-harmonic-conjugated-point-of-a-triplet-of-aligned-points "https://www.codewars.com/kata/5600e00e42bcb7b9dc00014e") - + The image shows how we can obtain the Harmonic Conjugated Point of three aligned points A, B, C. @@ -18,7 +18,7 @@ You can get more knowledge related with this point at: (https://en.wikipedia.org If we apply the theorems of Ceva (https://en.wikipedia.org/wiki/Ceva%27s_theorem) and Menelaus (https://en.wikipedia.org/wiki/Menelaus%27_theorem) we will have this formula: - + AC, in the above formula is the length of the segment of points A to C in this direction and its value is: diff --git a/kata/7-kyu/collatz-conjecture-length/README.md b/kata/7-kyu/collatz-conjecture-length/README.md index 46ec0b007..6a3fb1497 100644 --- a/kata/7-kyu/collatz-conjecture-length/README.md +++ b/kata/7-kyu/collatz-conjecture-length/README.md @@ -8,4 +8,4 @@ For example, if n = 20, the resulting sequence will be: Write a program that will output the length of the Collatz Conjecture for any given n. In the example above, the output would be 8. -For more reading see: http://en.wikipedia.org/wiki/Collatz_conjecture \ No newline at end of file +For more reading see: https://en.wikipedia.org/wiki/Collatz_conjecture \ No newline at end of file diff --git a/kata/7-kyu/complementary-dna/README.md b/kata/7-kyu/complementary-dna/README.md index bbfc526ac..d3ec4975e 100644 --- a/kata/7-kyu/complementary-dna/README.md +++ b/kata/7-kyu/complementary-dna/README.md @@ -2,7 +2,7 @@ Deoxyribonucleic acid (DNA) is a chemical found in the nucleus of cells and carries the "instructions" for the development and functioning of living organisms. -If you want to know more http://en.wikipedia.org/wiki/DNA +If you want to know more https://en.wikipedia.org/wiki/DNA In DNA strings, symbols "A" and "T" are complements of each other, as "C" and "G". You have function with one side of the DNA (string, except for Haskell); you need to get the other complementary side. DNA strand is never empty or there is no DNA at all (again, except for Haskell). diff --git a/kata/7-kyu/easy-line/README.md b/kata/7-kyu/easy-line/README.md index 6969f1eff..183c8a6ba 100644 --- a/kata/7-kyu/easy-line/README.md +++ b/kata/7-kyu/easy-line/README.md @@ -18,9 +18,9 @@ easyline(4) => 70 easyline(50) => 100891344545564193334812497256 ``` ## Ref: -http://mathworld.wolfram.com/BinomialCoefficient.html +https://mathworld.wolfram.com/BinomialCoefficient.html -![alternative text](http://i.imgur.com/eUGaNvIm.jpg) +![alternative text](https://i.imgur.com/eUGaNvIm.jpg) ## Note: In Javascript, Coffeescript, Typescript, C++, PHP, C, R, Nim to get around the fact that we have no big integers diff --git a/kata/7-kyu/folding-your-way-to-the-moon/README.md b/kata/7-kyu/folding-your-way-to-the-moon/README.md index 2e73ef14b..6de1c207c 100644 --- a/kata/7-kyu/folding-your-way-to-the-moon/README.md +++ b/kata/7-kyu/folding-your-way-to-the-moon/README.md @@ -1,6 +1,6 @@ # [Folding your way to the moon](https://www.codewars.com/kata/folding-your-way-to-the-moon "https://www.codewars.com/kata/58f0ba42e89aa6158400000e") -Have you heard about the myth that [if you fold a paper enough times, you can reach the moon with it](http://scienceblogs.com/startswithabang/2009/08/31/paper-folding-to-the-moon/)? Sure you do, but exactly how many? Maybe it's time to write a program to figure it out. +Have you heard about the myth that [if you fold a paper enough times, you can reach the moon with it](https://scienceblogs.com/startswithabang/2009/08/31/paper-folding-to-the-moon)? Sure you do, but exactly how many? Maybe it's time to write a program to figure it out. You know that a piece of paper has a thickness of `0.0001m`. Given `distance` in units of meters, calculate how many times you have to fold the paper to make the paper reach this distance. (If you're not familiar with the concept of folding a paper: Each fold doubles its total thickness.) diff --git a/kata/7-kyu/herding-cats/README.md b/kata/7-kyu/herding-cats/README.md index 0fee591ed..f7da2d833 100644 --- a/kata/7-kyu/herding-cats/README.md +++ b/kata/7-kyu/herding-cats/README.md @@ -23,8 +23,8 @@ By default, this will sort the cats by their names. Your job is to complete the You may assume that no two cats have the same name. -For more information about ```Arrays```, take a look at http://docs.oracle.com/javase/7/docs/api/java/util/Arrays.html. +For more information about ```Arrays```, take a look at https://docs.oracle.com/javase/7/docs/api/java/util/Arrays.html. -For more information about ```Comparable```, see http://docs.oracle.com/javase/7/docs/api/java/lang/Comparable.html. +For more information about ```Comparable```, see https://docs.oracle.com/javase/7/docs/api/java/lang/Comparable.html. -For more information about ```Comparator```, check out http://docs.oracle.com/javase/7/docs/api/java/util/Comparator.html. \ No newline at end of file +For more information about ```Comparator```, check out https://docs.oracle.com/javase/7/docs/api/java/util/Comparator.html. \ No newline at end of file diff --git a/kata/7-kyu/hungarian-vowel-harmony-easy/README.md b/kata/7-kyu/hungarian-vowel-harmony-easy/README.md index 58d20d264..77495786f 100644 --- a/kata/7-kyu/hungarian-vowel-harmony-easy/README.md +++ b/kata/7-kyu/hungarian-vowel-harmony-easy/README.md @@ -4,7 +4,7 @@ ## Task: -Your goal is to create a function `dative()` (`Dative()` in C#) which returns the valid form of a valid Hungarian word `w` in [dative case](http://www.hungarianreference.com/Nouns/nak-nek-dative.aspx) i.e. append the correct suffix `nek` or `nak` to the word `w` based on vowel harmony rules. +Your goal is to create a function `dative()` (`Dative()` in C#) which returns the valid form of a valid Hungarian word `w` in [dative case](https://www.hungarianreference.com/Nouns/nak-nek-dative.aspx) i.e. append the correct suffix `nek` or `nak` to the word `w` based on vowel harmony rules. ## Vowel Harmony Rules (simplified) diff --git a/kata/7-kyu/java-functional-programming-part-1-the-beginning/README.md b/kata/7-kyu/java-functional-programming-part-1-the-beginning/README.md index c060e08e0..12854f134 100644 --- a/kata/7-kyu/java-functional-programming-part-1-the-beginning/README.md +++ b/kata/7-kyu/java-functional-programming-part-1-the-beginning/README.md @@ -11,7 +11,7 @@ String myString = f.apply(myObject); //Stores whatever the toString() of myObjec The above is a simple mapper function: given an input of type MyObject, return a specific result of type String, in this case the toString of the object. They can, of course, become much more complicated. -A full listing of the default function types can be found at http://docs.oracle.com/javase/8/docs/api/java/util/function/package-summary.html +A full listing of the default function types can be found at https://docs.oracle.com/javase/8/docs/api/java/util/function/package-summary.html Given this POJO: diff --git a/kata/7-kyu/java-functional-programming-part-2-multiline-functions/README.md b/kata/7-kyu/java-functional-programming-part-2-multiline-functions/README.md index ccee1716f..e83efd554 100644 --- a/kata/7-kyu/java-functional-programming-part-2-multiline-functions/README.md +++ b/kata/7-kyu/java-functional-programming-part-2-multiline-functions/README.md @@ -44,4 +44,4 @@ The formula for triangle area is: 1/2 \* base \* height Assume valid input (base and height are both greater than 0). -A full listing of the default function types can be found at http://docs.oracle.com/javase/8/docs/api/java/util/function/package-summary.html \ No newline at end of file +A full listing of the default function types can be found at https://docs.oracle.com/javase/8/docs/api/java/util/function/package-summary.html \ No newline at end of file diff --git a/kata/7-kyu/java-functional-programming-part-3-closured-for-business/README.md b/kata/7-kyu/java-functional-programming-part-3-closured-for-business/README.md index 7c8df32b7..6bd983819 100644 --- a/kata/7-kyu/java-functional-programming-part-3-closured-for-business/README.md +++ b/kata/7-kyu/java-functional-programming-part-3-closured-for-business/README.md @@ -45,4 +45,4 @@ f.applyAsInt(10) == 11; f.applyAsInt(-5) == -4; ``` -A full listing of the default function types can be found at http://docs.oracle.com/javase/8/docs/api/java/util/function/package-summary.html \ No newline at end of file +A full listing of the default function types can be found at https://docs.oracle.com/javase/8/docs/api/java/util/function/package-summary.html \ No newline at end of file diff --git a/kata/7-kyu/n-dimensional-vector-magnitude/README.md b/kata/7-kyu/n-dimensional-vector-magnitude/README.md index d2e292f4c..1f236ef23 100644 --- a/kata/7-kyu/n-dimensional-vector-magnitude/README.md +++ b/kata/7-kyu/n-dimensional-vector-magnitude/README.md @@ -7,4 +7,4 @@ The array will always contain at least 2 and at most 100 elements (2 ≤ vector.
An array containing four elements represents a vector in 4D space. -More info on finding the length of a vector: http://farside.ph.utexas.edu/teaching/301/lectures/node28.html \ No newline at end of file +More info on finding the length of a vector: https://farside.ph.utexas.edu/teaching/301/lectures/node28.html \ No newline at end of file diff --git a/kata/7-kyu/product-of-the-main-diagonal-of-a-square-matrix/README.md b/kata/7-kyu/product-of-the-main-diagonal-of-a-square-matrix/README.md index b105865fd..d61c4f3e6 100644 --- a/kata/7-kyu/product-of-the-main-diagonal-of-a-square-matrix/README.md +++ b/kata/7-kyu/product-of-the-main-diagonal-of-a-square-matrix/README.md @@ -9,4 +9,4 @@ Examples: [[1, 2, 3], [4, 5, 6], [7, 8, 9]] should return 45 ``` -http://en.wikipedia.org/wiki/Main_diagonal \ No newline at end of file +https://en.wikipedia.org/wiki/Main_diagonal \ No newline at end of file diff --git a/kata/7-kyu/red-knight/README.md b/kata/7-kyu/red-knight/README.md index 7ade786bb..74fbc2a32 100644 --- a/kata/7-kyu/red-knight/README.md +++ b/kata/7-kyu/red-knight/README.md @@ -31,7 +31,7 @@ Input = 0, 4; Output = new PawnDistance("White", 8); ``` - + background diff --git a/kata/7-kyu/thinkful-number-drills-congo-warehouses/README.md b/kata/7-kyu/thinkful-number-drills-congo-warehouses/README.md index 91c0e108b..c4b2806a5 100644 --- a/kata/7-kyu/thinkful-number-drills-congo-warehouses/README.md +++ b/kata/7-kyu/thinkful-number-drills-congo-warehouses/README.md @@ -1,6 +1,6 @@ # [Thinkful - Number Drills: Congo warehouses](https://www.codewars.com/kata/thinkful-number-drills-congo-warehouses "https://www.codewars.com/kata/5862e7c63f8628a126000e18") -Your company, [Congo Pizza](http://interesting-africa-facts.com/Africa-Landforms/Congo-Rainforest-Facts.html), +Your company, [Congo Pizza](https://interesting-africa-facts.com/Africa-Landforms/Congo-Rainforest-Facts.html), is the second-largest online frozen pizza retailer. You own a number of international warehouses that you use to store your frozen pizzas, and you need to figure out how many crates of pizzas you can store at each location. diff --git a/kata/7-kyu/triangles-from-dots/README.md b/kata/7-kyu/triangles-from-dots/README.md index df93abfd8..649075641 100644 --- a/kata/7-kyu/triangles-from-dots/README.md +++ b/kata/7-kyu/triangles-from-dots/README.md @@ -2,6 +2,6 @@ In this simple kata you need to find how many dots are needed to construct `n`th triangle in the sequence of dot triangles. See next image to get the idea of the sequence: -![sequence](http://www.mathsisfun.com/numbers/images/triangular-number-dots.svg) +![sequence](https://www.mathsisfun.com/numbers/images/triangular-number-dots.svg) You need to write a function that will return a number dots needed to construct `n`th triangle. \ No newline at end of file diff --git a/kata/8-kyu/8kyu-interpreters-hq9-plus/README.md b/kata/8-kyu/8kyu-interpreters-hq9-plus/README.md index 2728305b5..a962f9217 100644 --- a/kata/8-kyu/8kyu-interpreters-hq9-plus/README.md +++ b/kata/8-kyu/8kyu-interpreters-hq9-plus/README.md @@ -4,7 +4,7 @@ You task is to implement an simple interpreter for the notorious esoteric langua - If the input is `'H'`, return `'Hello World!'` - If the input is `'Q'`, return the input -- If the input is `'9'`, return the full lyrics of [99 Bottles of Beer](http://www.99-bottles-of-beer.net/lyrics.html). It should be formatted like this: +- If the input is `'9'`, return the full lyrics of [99 Bottles of Beer](https://www.99-bottles-of-beer.net/lyrics.html). It should be formatted like this: ```if:rust __Note__: In Rust, return `Some` containing the appropriate value. diff --git a/kata/8-kyu/age-range-compatibility-equation/README.md b/kata/8-kyu/age-range-compatibility-equation/README.md index 70a929190..2502e838c 100644 --- a/kata/8-kyu/age-range-compatibility-equation/README.md +++ b/kata/8-kyu/age-range-compatibility-equation/README.md @@ -5,7 +5,7 @@ classic ["half your age plus seven"](https://en.wikipedia.org/wiki/Age_disparity dating rule that a lot of people follow (including myself). It's the 'recommended' age range in which to date someone. -![](https://web.archive.org/web/20190206114947if_/http://weknowmemes.com/wp-content/uploads/2014/08/age-range-compatibility-equation.jpg) +![](https://web.archive.org/web/20190206114947if_/https://weknowmemes.com/wp-content/uploads/2014/08/age-range-compatibility-equation.jpg) ```minimum age <= your age <= maximum age``` diff --git a/kata/8-kyu/area-of-a-square/README.md b/kata/8-kyu/area-of-a-square/README.md index 8aff33bfc..08a6cafcb 100644 --- a/kata/8-kyu/area-of-a-square/README.md +++ b/kata/8-kyu/area-of-a-square/README.md @@ -2,7 +2,7 @@ Write the function `squareArea` ( or `square_area` ) that finds the area of the red square when you have the length of the circular arc `A`. -![Graph](http://i.imgur.com/nJrae8n.png) +![Graph](https://i.imgur.com/nJrae8n.png) * Use ? = Math.PI ( `M_PI` in PHP ) - * Round to two decimals + * Round to two decimals \ No newline at end of file diff --git a/kata/8-kyu/basic-subclasses-adam-and-eve/test/GodTest.java b/kata/8-kyu/basic-subclasses-adam-and-eve/test/GodTest.java index 972f1e6e9..04b76a0d8 100644 --- a/kata/8-kyu/basic-subclasses-adam-and-eve/test/GodTest.java +++ b/kata/8-kyu/basic-subclasses-adam-and-eve/test/GodTest.java @@ -1,10 +1,10 @@ -import static org.junit.jupiter.api.Assertions.assertTrue; +import static org.junit.jupiter.api.Assertions.assertInstanceOf; import org.junit.jupiter.api.Test; class GodTest { @Test void sample() { - assertTrue(God.create()[0] instanceof Man); + assertInstanceOf(Man.class, God.create()[0]); } -} +} \ No newline at end of file diff --git a/kata/8-kyu/cat-years-dog-years/README.md b/kata/8-kyu/cat-years-dog-years/README.md index 267f5d45b..c820ca065 100644 --- a/kata/8-kyu/cat-years-dog-years/README.md +++ b/kata/8-kyu/cat-years-dog-years/README.md @@ -28,11 +28,9 @@ NOTES: **References** -* http://www.catster.com/cats-101/calculate-cat-age-in-cat-years -* http://www.slate.com/articles/news_and_politics/explainer/2009/05/a_dogs_life.html +* https://www.catster.com/guides/how-old-is-my-cat +* https://slate.com/news-and-politics/2009/05/how-do-you-calculate-dog-years.html
-If you liked this Kata there is another related one here - - +If you liked this Kata there is another related one here \ No newline at end of file diff --git a/kata/8-kyu/convert-a-string-to-a-number/README.md b/kata/8-kyu/convert-a-string-to-a-number/README.md index 233078e9e..619ec0413 100644 --- a/kata/8-kyu/convert-a-string-to-a-number/README.md +++ b/kata/8-kyu/convert-a-string-to-a-number/README.md @@ -1,6 +1,6 @@ # [Convert a String to a Number!](https://www.codewars.com/kata/convert-a-string-to-a-number "https://www.codewars.com/kata/544675c6f971f7399a000e79") -Note: This kata is inspired by [Convert a Number to a String!](http://www.codewars.com/kata/convert-a-number-to-a-string/). Try that one too. +Note: This kata is inspired by [Convert a Number to a String!](https://www.codewars.com/kata/convert-a-number-to-a-string). Try that one too. ## Description diff --git a/kata/8-kyu/get-character-from-ascii-value/README.md b/kata/8-kyu/get-character-from-ascii-value/README.md index 44b387ebf..8c1ec3b21 100644 --- a/kata/8-kyu/get-character-from-ascii-value/README.md +++ b/kata/8-kyu/get-character-from-ascii-value/README.md @@ -8,4 +8,4 @@ Example: Ascii.getChar(65) // => 'A' ``` -For ASCII table, you can refer to http://www.asciitable.com/ \ No newline at end of file +For ASCII table, you can refer to https://www.asciitable.com \ No newline at end of file diff --git a/kata/8-kyu/how-many-stairs-will-suzuki-climb-in-20-years/test/KataTests.java b/kata/8-kyu/how-many-stairs-will-suzuki-climb-in-20-years/test/KataTests.java index 1a38cedc6..8a7f50752 100644 --- a/kata/8-kyu/how-many-stairs-will-suzuki-climb-in-20-years/test/KataTests.java +++ b/kata/8-kyu/how-many-stairs-will-suzuki-climb-in-20-years/test/KataTests.java @@ -1,10 +1,13 @@ import static org.junit.jupiter.api.Assertions.assertEquals; +import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; class KataTests { - @Test - void sample() { + private int[][] stairs; + + @BeforeEach + void setUp() { int[] sunday = { 6737, 7244, 5776, 9826, 7057, 9247, 5842, 5484, 6543, 5153, 6832, 8274, 7148, 6152, 5940, 8040, 9174, 7555, 7682, 5252, 8793, 8837, 7320, 8478, 6063, 5751, 9716, 5085, 7315, 7859, @@ -53,7 +56,11 @@ void sample() { 5163, 6656, 8150, 8826, 6875, 5242, 9585, 9649, 9838, 7150, 6567, 8524, 7613, 7809, 5562, 7799, 7179, 5184, 7960, 9455, 5633, 9085 }; - int[][] stairs = {sunday, monday, tuesday, wednesday, thursday, friday, saturday}; + stairs = new int[][]{sunday, monday, tuesday, wednesday, thursday, friday, saturday}; + } + + @Test + void sample() { assertEquals(54636040, Kata.stairsIn20(stairs)); } -} +} \ No newline at end of file diff --git a/kata/8-kyu/localize-the-barycenter-of-a-triangle/README.md b/kata/8-kyu/localize-the-barycenter-of-a-triangle/README.md index e33302dae..c19d16eef 100644 --- a/kata/8-kyu/localize-the-barycenter-of-a-triangle/README.md +++ b/kata/8-kyu/localize-the-barycenter-of-a-triangle/README.md @@ -1,6 +1,6 @@ # [Localize The Barycenter of a Triangle](https://www.codewars.com/kata/localize-the-barycenter-of-a-triangle "https://www.codewars.com/kata/5601c5f6ba804403c7000004") - + The medians of a triangle are the segments that unit the vertices with the midpoint of their opposite sides. The three medians of a triangle intersect at the same point, called the barycenter or the centroid. @@ -13,7 +13,7 @@ the result of the coordinates should be expressed up to four decimals, (rounded You know that the coordinates of the barycenter are given by the following formulas. - + For additional information about this important point of a triangle see at: (https://en.wikipedia.org/wiki/Centroid) @@ -24,7 +24,4 @@ barTriang([4, 6], [12, 4], [10, 10]) ------> {8.6667, 6.6667} barTriang([4, 2], [12, 2], [6, 10] ------> {7.3333, 4.6667} ``` -The given points form a real or a degenerate triangle but in each case the above formulas can be used. - -Enjoy it and happy coding!! - +The given points form a real or a degenerate triangle but in each case the above formulas can be used. \ No newline at end of file diff --git a/kata/8-kyu/rock-paper-scissors/README.md b/kata/8-kyu/rock-paper-scissors/README.md index 87b8ea8bf..911b5c2fa 100644 --- a/kata/8-kyu/rock-paper-scissors/README.md +++ b/kata/8-kyu/rock-paper-scissors/README.md @@ -9,4 +9,4 @@ rps('scissors','rock') // Player 2 won! rps('paper','paper') // Draw! ``` -![rockpaperscissors](http://i.imgur.com/aimOQVX.png) \ No newline at end of file +![rockpaperscissors](https://i.imgur.com/aimOQVX.png) \ No newline at end of file diff --git a/kata/beta/letter-to-ascii/README.md b/kata/beta/letter-to-ascii/README.md index f4038b082..b6015fd09 100644 --- a/kata/beta/letter-to-ascii/README.md +++ b/kata/beta/letter-to-ascii/README.md @@ -6,4 +6,4 @@ You will be given a character, and you will convert it to its corresponding numb Ex. 'a' = 97 -Here is a link to an ASCII table: http://www.asciitable.com/ \ No newline at end of file +Here is a link to an ASCII table: https://www.asciitable.com \ No newline at end of file diff --git a/kata/beta/string-calculator-with-different-input-types/README.md b/kata/beta/string-calculator-with-different-input-types/README.md index 88ea37eee..3b02977f4 100644 --- a/kata/beta/string-calculator-with-different-input-types/README.md +++ b/kata/beta/string-calculator-with-different-input-types/README.md @@ -33,9 +33,8 @@ Output: "6" private static Optional parseIntHelper(String number); ``` 2. Convert split string into a stream -3. Use map-reduce paradigm: - * http://www.techspot.co.in/2011/07/mapreduce-for-dummies.html +3. Use map-reduce paradigm 4. APIs for use: - * https://docs.oracle.com/javase/8/docs/api/java/util/Arrays.html + * https://docs.oracle.com/javase/8/docs/api/java/util/Arrays.html * https://docs.oracle.com/javase/8/docs/api/java/util/stream/Stream.html * https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html diff --git a/kata/beta/tug-o-war/README.md b/kata/beta/tug-o-war/README.md index df5de01e0..a09cfd04a 100644 --- a/kata/beta/tug-o-war/README.md +++ b/kata/beta/tug-o-war/README.md @@ -21,7 +21,7 @@ If the two teams are of equal strength, the team with the strongest Anchor (the The Anchors are members in each end of the rope: -![anchors](http://i.imgur.com/w3MJF2V.jpg?1) +![anchors](https://i.imgur.com/w3MJF2V.jpg) more examples: diff --git a/kata/retired/bad-hash-string-to-string/README.md b/kata/retired/bad-hash-string-to-string/README.md index b29456c85..db6cf6d93 100644 --- a/kata/retired/bad-hash-string-to-string/README.md +++ b/kata/retired/bad-hash-string-to-string/README.md @@ -28,6 +28,6 @@ convertIntHashed(magicNum): ``` **Note:** OR, AND, NOT, XOR are bitwise operations and all bit shift are logical bit shift. -[Ascii Table](http://www.asciitable.com/index/asciifull.gif) +[Ascii Table](https://www.asciitable.com) Give an example why this hashing algorithm is bad? \ No newline at end of file diff --git a/kata/retired/positive-and-negative-regex/README.md b/kata/retired/positive-and-negative-regex/README.md index 7bef2d2f6..107b82af3 100644 --- a/kata/retired/positive-and-negative-regex/README.md +++ b/kata/retired/positive-and-negative-regex/README.md @@ -27,4 +27,4 @@ tap Of course, you don't want to hard-code the given examples, because such a solution would not pass the final anti-hard-code-random-value test that uses the same regex pattern you have to find. -Hint: http://rubular.com/r/J2mE8vdhjb will be of great assistance in constructing your regular expression. \ No newline at end of file +Hint: https://rubular.com/r/J2mE8vdhjb will be of great assistance in constructing your regular expression. \ No newline at end of file diff --git a/kata/retired/sudoku-solution-validator/README.md b/kata/retired/sudoku-solution-validator/README.md index 1c23df37c..cc6ce1706 100644 --- a/kata/retired/sudoku-solution-validator/README.md +++ b/kata/retired/sudoku-solution-validator/README.md @@ -5,7 +5,7 @@ Sudoku is a game played on a 9x9 grid. The goal of the game is to fill all cells of the grid with digits from 1 to 9, so that each column, each row, and each of the nine 3x3 sub-grids (also known as blocks) contain all the digits from 1 to 9.
-(More info at: http://en.wikipedia.org/wiki/Sudoku) +(More info at: https://en.wikipedia.org/wiki/Sudoku) ### Sudoku Solution Validator diff --git a/kata/retired/thinkful-number-drills-pixelart-planning/README.md b/kata/retired/thinkful-number-drills-pixelart-planning/README.md index 54bda37ea..8fb082dcd 100644 --- a/kata/retired/thinkful-number-drills-pixelart-planning/README.md +++ b/kata/retired/thinkful-number-drills-pixelart-planning/README.md @@ -1,6 +1,6 @@ # [Thinkful - Number Drills: Pixelart planning](https://www.codewars.com/kata/thinkful-number-drills-pixelart-planning "https://www.codewars.com/kata/58630e2ae88af44d2b0000ea") -You're laying out a rad pixel art mural to paint on your living room wall in homage to [Paul Robertson](http://68.media.tumblr.com/0f55f7f3789a354cfcda7c2a64f501d1/tumblr_o7eq3biK9s1qhccbco1_500.png), your favorite pixel artist. +You're laying out a rad pixel art mural to paint on your living room wall in homage to [Paul Robertson](https://68.media.tumblr.com/0f55f7f3789a354cfcda7c2a64f501d1/tumblr_o7eq3biK9s1qhccbco1_500.png), your favorite pixel artist. You want your work to be perfect down to the millimeter. You haven't decided on the dimensions of your piece, how large you want your pixels to be, or which wall you want to use. You just know that you want to fit an exact number of pixels. diff --git a/kata/retired/vasya-and-system-of-equations/README.md b/kata/retired/vasya-and-system-of-equations/README.md index 6e2fe4709..cc28e5bdc 100644 --- a/kata/retired/vasya-and-system-of-equations/README.md +++ b/kata/retired/vasya-and-system-of-equations/README.md @@ -8,7 +8,7 @@ Finally, today is the time to show what Vasya achieved. He solved the given task You are given a system of equations: -![](http://i.imgur.com/jMml8Tc.png) +![](https://i.imgur.com/jMml8Tc.png) In JS, C# and Java the parameters of the system: `1 ≤ n, m ≤ 1000`