Sign up
Log in
Home
Language tracks
Dart track
Exercises
Exercises on the Dart track
Join the Dart Track
36 exercises to help you master Dart
easy
Hello World
The classical introductory exercise. Just say "Hello, World!"
optional values
strings
text formatting
conditionals
easy
Resistor Color
Convert a resistor band's color to its numeric representation
arrays
strings
easy
Two Fer
Create a sentence of the form "One for X, one for me."
conditionals
optional values
text formatting
easy
Resistor Color Duo
Convert color codes, as used on resistors, to a numeric value.
arrays
strings
easy
Reverse String
Reverse a string
strings
easy
Leap
Given a year, report if it is a leap year.
booleans
integers
logic
easy
Scrabble Score
Given a word, compute the Scrabble score for that word.
equality
strings
conditionals
loops
easy
Beer Song
Produce the lyrics to that beloved classic, that field-trip favorite: 99 Bottles of Beer on the Wall.
loops
strings
text formatting
easy
Armstrong Numbers
Determine if a number is an Armstrong number
equality
integers
logic
strings
math
easy
Isogram
Determine if a word or phrase is an isogram.
algorithms
logic
strings
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.
integers
math
easy
Word Count
Given a phrase, count the occurrences of each word in that phrase.
lists
maps
regular expressions
loops
easy
Bob
Bob is a lackadaisical teenager. In conversation, his responses are very limited.
pattern recognition
polymorphism
regular expressions
strings
conditionals
easy
Space Age
Given an age in seconds, calculate how old someone is in terms of a given planet's solar years.
floating point numbers
integers
math
polymorphism
easy
Hamming
Calculate the Hamming difference between two DNA strands.
equality
strings
conditionals
loops
easy
Acronym
Convert a long phrase to its acronym
equality
regular expressions
strings
conditionals
loops
easy
Phone Number
Clean up user-entered phone numbers so that they can be sent SMS messages.
regular expressions
conditionals
loops
easy
Gigasecond
Given a moment, determine the moment that would be after a gigasecond has passed.
time
easy
Raindrops
Convert a number to a string, the content of which depends on the number's factors.
equality
strings
conditionals
easy
RNA Transcription
Given a DNA strand, return its RNA Complement Transcription.
strings
transforming
easy
Anagram
Given a word and a list of possible anagrams, select the correct sublist.
equality
strings
conditionals
loops
easy
Prime Factors
Compute the prime factors of a given natural number.
arrays
conditionals
integers
lists
loops
math
easy
Diamond
Given a letter, print a diamond starting with 'A' with the supplied letter at the widest point.
strings
conditionals
loops
easy
Matching Brackets
Make sure the brackets and braces all match.
pattern matching
stacks
easy
Pascal's Triangle
Compute Pascal's triangle up to a given number of rows.
integers
lists
math
conditionals
loops
easy
Darts
Write a function that returns the earned points in a single toss of a Darts game
math
conditionals
easy
Pangram
Determine if a sentence is a pangram.
pattern matching
regular expressions
sets
strings
medium
Luhn
Given a number determine whether or not it is valid per the Luhn formula.
algorithms
booleans
loops
strings
type conversion
medium
Minesweeper
Add the numbers to a minesweeper board
classes
games
lists
logic
loops
math
object oriented programming
medium
ISBN Verifier
Check if a given string is a valid ISBN-10 number.
integers
loops
strings
easy
Collatz Conjecture
Calculate the number of steps to reach 1 using the Collatz conjecture
exception handling
loops
math
medium
Binary Search Tree
Insert and search for numbers in a binary tree.
algorithms
classes
generics
inheritance
logic
object oriented programming
searching
sorting
trees
easy
Nth Prime
Given a number n, determine what the nth prime is.
algorithms
integers
math
easy
Allergies
Given a person's allergy score, determine whether or not they're allergic to a given item, and their full list of allergies.
arrays
bitwise operations
conditionals
loops
easy
Triangle
Determine if a triangle is equilateral, isosceles, or scalene.
conditionals
loops
medium
Secret Handshake
Given a decimal number, convert it to the appropriate sequence of events for a secret handshake.
arrays
bitwise operations
integers