Most of these problems are taken from exercism.io !
The exercises are ordered roughly in order of difficulty, but it's a bit haphazard.
run the selected source.
mvn test
# Install Gradle
$ sudo apt-get install gradle
# Go inside your project folder and:
$ gradle test
In this challenge, you have two ways for write your TDD
- clone all repo and make a Maven project with Junit4 (or Junit5)
- copy the class and his test in this project
http://www.commitstrip.com/fr/2016/02/22/when-the-functional-tests-are-all-red/
Write a function that greets the user by name, or by saying "Hello, World!" if no name is given.
We are going to do the `Transform` step of an Extract-Transform-Load.
Given a DNA string, compute how many times each nucleotide occurs in the string.
Write a program that given a phrase can count the occurrences of each word in that phrase.
Determine if a sentence is a pangram.
Write a program that, given a word and a list of possible anagrams, selects the correct sublist.
Write a program that can calculate the Hamming difference between two DNA strands.
Bob is a lackadaisical teenager. In conversation, his responses are very limited.
Write a program that manages robot factory settings.
Calculate the date of meetups.
README Write a program that cleans up user-entered phone numbers so that they can be sent SMS messages.
Write a small archiving program that stores students' names along with the grade that they are in.
Write a program that, given an age in seconds, calculates how old someone is in terms of a given planet's solar years.
Write a program that calculates the moment when someone has lived for 10^9 seconds.
Write a program that can tell you if a triangle is equilateral, isosceles, or scalene.
Convert a long phrase to its acronym
Write a program that, given a word, computes the scrabble score for that word.
Write a function to convert from normal numbers to Roman Numerals.
Compute the prime factors of a given natural number.
Write a program that converts a number to a string, the contents of which depend on the number's factors.
Write a program that, given a person's allergy score, can tell them whether or not they're allergic to a given item, and their full list of allergies.
Implement the `keep` and `discard` operation on collections. Given a collection and a predicate on the collection's elements, `keep` returns a new collection containing those elements where the predicate is true, while `discard` returns a new collection containing those elements where the predicate is false.
Create an implementation of the atbash cipher, an ancient encryption system created in the Middle East.
Implement the `accumulate` operation, which, given a collection and an operation to perform on each element of the collection, returns a new collection containing the result of applying that operation to each element of the input collection.
Implement the classic method for composing secret messages called a square code.
Write a program that, given a DNA strand, returns its RNA complement (per RNA transcription).
Write a program that uses the Sieve of Eratosthenes to find all the primes from 2 up to a given number.
Implement a simple shift cipher like Caesar and a more secure substitution cipher
Write a program that can take a number and determine whether or not it is valid per the Luhn formula.
Implement a program that translates from English to Pig Latin
Write a simple linked list implementation that uses Elements and a List
Write a program that, given a number, can find the sum of all the multiples of particular numbers up to but not including that number.
Implement a doubly linked list
Write a program that can tell you what the nth prime is.
Write a program that computes Pascal's triangle up to a given number of rows.
Write a program which produces the lyrics to that beloved classic, that field-trip favorite: 99 Bottles of Beer on the Wall.
Find the difference between the sum of the squares and the square of the sums of the first N natural numbers.
Write a program that, when given a string of digits, can calculate the largest product for a contiguous substring of digits of length n.
Write a program that positions two queens on a chess board and indicates whether or not they are positioned so that they can attack each other.
Write a program that adds the numbers to a minesweeper board
Write a program that will take a string of digits and give you all the contiguous substrings of length `n` in that string.
Write a robot simulator.
Make sure the brackets and braces all match.
There exists exactly one Pythagorean triplet for which a + b + c = 1000. Find the product a * b * c.
Write a program that inserts numbers and searches in a binary tree.
Write a program that implements a binary search algorithm.
Write a program that will convert a number, represented as a sequence of digits in one base, to any other base.
Create a custom set type.
Parse and evaluate simple math word problems returning the answer as an integer.
Write a program that can detect palindrome products in a given range.