Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

Exercism

Ballerina

via Exercism

Overview

Coursera Flash Sale
40% Off Coursera Plus for 3 Months!
Grab it
Get fluent in Ballerina by solving 60 exercises. And then level up with mentoring from our world-class team.

Syllabus

  • Hello World
    • Exercism's classic introductory exercise. Just say "Hello, World!".
  • Calculator Service
    • HTTP endpoints are better with type checking. Adding a Record type to a POST request will ensure the correct data is sent every time.
  • Echo Service
    • Creating a service in ballerina is easy. Now you can add a query parameter and a relative path.
  • Service Error Handling
    • Implement various kinds of error handling and resource management.
  • Greeting Service
    • Make an HTTP service to say "Hello".
  • Hello World Service
    • The classical introductory exercise. Just create an HTTP service to say "Hello, World!".
  • Service Composition
    • In this exercise, you will use Ballerina Records to organize the request payloads and ensure successful communication with external reservation endpoints.
  • Service Invocation
    • Calling APIs is an important part of writing code on the internet.
  • CSV Fuel Allowance
    • As a member of the digital operations team, your task is to read this CSV file and write the results to another CSV file.
  • JSON Fuel Allowance
    • As a member of the digital operations team, your task is to read this JSON file and write the results to another JSON file.
  • XML Fuel Allowance
    • As a member of the digital operations team, your task is to read this XML file and write the results to another XML file.
  • Monitor Rush
    • Every employee wants to work in the new office because each cubicle has state-of-the-art monitors. The HR department is overwhelmed with such requests and came up with a cubicle allocation system with the help of its digital operations team.
  • The Cake is a Lie
    • A popular bakery that bakes various cakes, has asked you to set up an online order management system for them.
  • PaySwitch - Salary Converter
    • A company needs to convert salaries in foreign currencies to the corresponding local currency using an external API.
  • Armstrong Numbers
    • Determine if a number is an Armstrong number.
  • Game Of Life
    • Implement Conway's Game of Life.
  • Isogram
    • Determine if a word or phrase is an isogram.
  • Raindrops
    • Convert a number into its corresponding raindrop sounds - Pling, Plang and Plong.
  • Roman Numerals
    • Convert modern Arabic numbers into Roman numerals.
  • Space Age
    • Given an age in seconds, calculate how old someone is in terms of a given planet's solar years.
  • Acronym
    • Convert a long phrase to its acronym.
  • Sieve
    • Use the Sieve of Eratosthenes to find all the primes from 2 up to a given number.
  • Bob
    • Bob is a lackadaisical teenager. In conversation, his responses are very limited.
  • Collatz Conjecture
    • Calculate the number of steps to reach 1 using the Collatz conjecture.
  • Grains
    • Calculate the number of grains of wheat on a chessboard given that the number on each square doubles.
  • Knapsack
    • Given a knapsack that can only carry a certain weight, determine which items to put in the knapsack in order to maximize their combined value.
  • Hamming
    • Calculate the Hamming distance between two DNA strands.
  • Difference Of Squares
    • Find the difference between the square of the sum and the sum of the squares of the first N natural numbers.
  • Leap
    • Determine whether a given year is a leap year.
  • Darts
    • Calculate the points scored in a single toss of a Darts game.
  • Two Fer
    • Create a sentence of the form "One for X, one for me.".
  • Pangram
    • Determine if a sentence is a pangram.
  • Anagram
    • Given a word and a list of possible anagrams, select the correct sublist.
  • Atbash Cipher
    • Create an implementation of the Atbash cipher, an ancient encryption system created in the Middle East.
  • Protein Translation
    • Translate RNA sequences into proteins.
  • ETL
    • Change the data format for scoring a game to more easily add other languages.
  • Pascal's Triangle
    • Compute Pascal's triangle up to a given number of rows.
  • Two Bucket
    • Given two buckets of different size, demonstrate how to measure an exact number of liters.
  • Binary Search
    • Implement a binary search algorithm.
  • Linked List
    • Implement a doubly linked list.
  • Largest Series Product
    • Given a string of digits, calculate the largest product for a contiguous substring of digits of length n.
  • Matching Brackets
    • Make sure the brackets and braces all match.
  • Robot Simulator
    • Write a robot simulator.
  • Saddle Points
    • Detect saddle points in a matrix.
  • Sum Of Multiples
    • Given a number, find the sum of all the multiples of particular numbers up to but not including that number.
  • Secret Handshake
    • Given a decimal number, convert it to the appropriate sequence of events for a secret handshake.
  • Kindergarten Garden
    • Given a diagram, determine which plants each child in the kindergarten class is responsible for.
  • Yacht
    • Score a single throw of dice in the game Yacht.
  • Reverse String
    • Reverse a given string.
  • Allergies
    • Given a person's allergy score, determine whether or not they're allergic to a given item, and their full list of allergies.
  • RNA Transcription
    • Given a DNA strand, return its RNA complement.
  • Triangle
    • Determine if a triangle is equilateral, isosceles, or scalene.
  • Scrabble Score
    • Given a word, compute the Scrabble score for that word.
  • Resistor Color
    • Convert a resistor band's color to its numeric representation.
  • Resistor Color Duo
    • Convert color codes, as used on resistors, to a numeric value.
  • Eliud's Eggs
    • Help Eliud count the number of eggs in her chicken coop by counting the number of 1 bits in a binary representation.
  • Circular Buffer
    • A data structure that uses a single, fixed-size buffer as if it were connected end-to-end.
  • List Ops
    • Implement basic list operations.
  • D&D Character
    • Randomly generate Dungeons & Dragons characters.
  • Rotational Cipher
    • Create an implementation of the rotational cipher, also sometimes called the Caesar cipher.

Reviews

Start your review of Ballerina

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.