ðŸŽ‰ Exercism Research is now launched. Help Exercism, help science and have some fun at
research.exercism.io
ðŸŽ‰
Sign up
Log in
Home
Language tracks
D track
Exercises
Exercises on the D track
Join the D Track
34 exercises to help you master D
easy
Hello World
The classical introductory exercise. Just say "Hello, World!"
language basics
easy
Leap
Given a year, report if it is a leap year.
language basics
easy
Gigasecond
Given a moment, determine the moment that would be after a gigasecond has passed.
language basics
time
easy
RNA Transcription
Given a DNA strand, return its RNA Complement Transcription.
control flow foreach
error handling
string manipulation
easy
Raindrops
Convert a number to a string, the content of which depends on the number's factors.
control flow if statements
language basics
easy
Bob
Bob is a lackadaisical teenager. In conversation, his responses are very limited.
control flow if statements
string manipulation
easy
ETL
We are going to do the `Transform` step of an Extract-Transform-Load.
associative arrays
control flow foreach
string manipulation
easy
Hamming
Calculate the Hamming difference between two DNA strands.
control flow foreach
error handling
easy
Nucleotide Count
Given a DNA string, compute how many times each nucleotide occurs in the string.
associative arrays
classes
parsing
easy
Robot Name
Manage robot factory settings.
classes
random numbers
easy
Difference Of Squares
Find the difference between the square of the sum and the sum of the squares of the first N natural numbers.
algorithms
control flow foreach
functional
template metaprogramming
math
easy
Roman Numerals
Write a function to convert from normal numbers to Roman Numerals.
conversions
functional
string manipulation
easy
Series
Given a string of digits, output all the contiguous substrings of length `n` in that string.
arrays
string manipulation
easy
Triangle
Determine if a triangle is equilateral, isosceles, or scalene.
control flow if statements
language basics
easy
Crypto Square
Implement the classic method for composing secret messages called a square code.
algorithms
classes
string manipulation
medium
Circular Buffer
A data structure that uses a single, fixed-size buffer as if it were connected end-to-end.
class templates
data structures
easy
Pangram
Determine if a sentence is a pangram.
control flow
language basics
string manipulation
hard
React
Implement a basic reactive system.
delegates
generics
higher order functions
nested classes
reactive programming
medium
Run Length Encoding
Implement run-length encoding and decoding.
algorithms
control flow if statements
strings
easy
Reverse String
Reverse a string
strings
easy
Collatz Conjecture
Calculate the number of steps to reach 1 using the Collatz conjecture
loops
math
easy
Armstrong Numbers
Determine if a number is an Armstrong number
algorithms
loops
math
easy
Two Fer
Create a sentence of the form "One for X, one for me."
conditionals
optional values
text formatting
easy
Isogram
Determine if a word or phrase is an isogram.
algorithms
conditionals
loops
maps
strings
easy
Darts
Write a function that returns the earned points in a single toss of a Darts game
conditionals
floating point numbers
math
easy
Resistor Color
Convert a resistor band's color to its numeric representation
arrays
strings
easy
Resistor Color Duo
Convert color codes, as used on resistors, to a numeric value.
arrays
transforming
easy
Perfect Numbers
Determine if a number is perfect, abundant, or deficient based on Nicomachus' (60 - 120 CE) classification scheme for natural numbers.
enumerations
exception handling
filtering
integers
math
easy
Sum Of Multiples
Given a number, find the sum of all the multiples of particular numbers up to but not including that number.
integers
math
easy
Prime Factors
Compute the prime factors of a given natural number.
integers
math
easy
Luhn
Given a number determine whether or not it is valid per the Luhn formula.
algorithms
integers
strings
easy
Nth Prime
Given a number n, determine what the nth prime is.
algorithms
lists
loops
math
easy
Matching Brackets
Make sure the brackets and braces all match.
parsing
recursion
stacks
strings
medium
Grains
Calculate the number of grains of wheat on a chessboard given that the number on each square doubles.
integers