Skip to content

salvatore-campagna/go-playground

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go Playground

This repository contains various Go exercises and projects that I’ve worked on to practice different programming concepts. Each project focuses on a specific challenge, ranging from algorithmic problems to practical applications, helping me deepen my understanding of Go.

Projects

airport-robot

A solution to the Airport Robot exercise on Exercism, which simulates a multilingual airport greeter system. The solution uses an interface to support greetings in multiple languages, allowing dynamic language selection for visitor greetings. See: Exercism - Airport Robot.

anagram

A solution to the Anagram exercise on Exercism, detecting anagrams of a given word from a list of candidates by comparing sorted character sequences. See: Exercism - Anagram.

animal-magic

A solution to the Animal Magic exercise on Exercism, which deals with string manipulation and Go's handling of Unicode characters.
See: Exercism - Animal Magic.

annalyns-infiltration

A solution to the Annalyn's Infiltration exercise, an introductory exercise on conditionals and control flow.
See: Exercism - Annalyn's Infiltration.

bird-watcher

A solution to the Bird Watcher exercise, focusing on slice manipulation and basic analytics.
See: Exercism - Bird Watcher.

bitset

Implemented a BitSet data structure using a slice of uint64 integers, allowing efficient storage and manipulation of bits. Supports setting, clearing, and testing bits with error handling.

blackjack

A solution to the Blackjack exercise on Exercism, involving control flow and strategy based on card game rules.
See: Exercism - Blackjack.

bloom-filter

Implemented a Bloom Filter, a probabilistic data structure for efficient membership testing with a low probability of false positives. Demonstrates working with hash functions and bit manipulation. Useful for scenarios like caching, spam filters, and database query optimizations.

bookstore

Created a Bookstore Inventory Manager to manage a bookstore's inventory using Go structs, methods, and slices. Includes features for adding books, checking stock, selling books, and calculating inventory value.

card-tricks

A solution to the Card Tricks exercise on Exercism, focusing on working with arrays and slices.
See: Exercism - Card Tricks.

cars-assemble

A solution to the Cars Assemble exercise, practicing control flow and simple calculations.
See: Exercism - Cars Assemble.

chessboard

A solution to the Chessboard exercise on Exercism, which involves counting squares on a chessboard represented using maps and slices. This exercise helps practice working with maps, slices, and loops in Go to efficiently analyze a chessboard's state. See: Exercism - Chessboard.

collatz-conjecture

A solution to the Collatz Conjecture exercise, implementing the famous mathematical sequence problem.
See: Exercism - Collatz Conjecture.

darts

A solution to the Darts exercise on Exercism, which involves calculating the score of a dart based on its (x, y) coordinates on a dartboard. The dartboard is divided into concentric circles with different scores. See: Exercism - Darts.

difference-of-squares

A solution to the Difference of Squares exercise, focusing on basic arithmetic and loops.
See: Exercism - Difference of Squares.

election-day

A solution to the Election Day exercise on Exercism, which involves managing election votes and results. The solution includes functionalities for handling vote counters, creating and displaying election results, and updating vote counts in a map of candidates. See: Exercism - Election Day.

elons-toys

A solution to the Elon's Toys exercise on Exercism, which simulates the behavior of a toy car. The solution includes functionality to drive the car, display its current battery and distance, and determine whether it can complete a given track. See: Exercism - Elon's Toys.

etl

A solution to the ETL exercise, focusing on transforming data formats from a legacy scoring system to a modern format.
See: Exercism - ETL.

fizzbuzz

A classic FizzBuzz implementation that uses control flow and modulus operations.

gigasecond

A solution to the Gigasecond exercise on Exercism, which involves adding exactly 1 gigasecond (1 billion seconds) to a given time value.
See: Exercism - Gigasecond.

gross-store

A solution to the Gross Store exercise on Exercism, which involves managing a grocery store billing system. The solution includes functions to: This exercise helps practice working with maps, constants, and function design in Go. See: Exercism - Gross Store.

guess-game

Created a number guessing game where players guess a randomly chosen number. Focuses on generating random numbers and handling user input.

hello-world

A simple Hello World program to get started with Go. Demonstrates Go's syntax and structure.

interest-is-interesting

A solution to the Interest Is Interesting exercise on Exercism, which involves calculating interest rates, updating balances annually, and determining the number of years required to reach a target balance. The solution implements various financial calculations based on predefined interest rates for different balance ranges.
See: Exercism - Interest Is Interesting.

isbn-verifier

A solution to the ISBN Verifier exercise on Exercism, which involves validating ISBN-10 codes based on specific rules. This exercise demonstrates working with string manipulation, rune validation, and implementing checksum calculations in Go. See: Exercism - ISBN Verifier.

isogram

A solution to the Isogram exercise, identifying whether a word contains repeating letters.
See: Exercism - Isogram.

largest-series-product

A solution to the Largest Series Product exercise on Exercism, calculating the largest product for a contiguous substring of digits with a specified span. See: [Exercism - Largest Series Product](https://exercism.org/tracks/go/exercises/la

lasagna

A solution to the Gopher's Gorgeous Lasagna exercise, practicing functions and return values.
See: Exercism - Lasagna.

lasagna-master

A solution to the Lasagna Master exercise on Exercism, which involves managing the preparation and cooking time of a lasagna recipe. The solution includes calculating preparation time, determining the required quantities of ingredients like noodles and sauce, adding secret ingredients, and scaling recipes based on the number of portions. This exercise helps practice using constants, slices, and basic calculations in Go. See: Exercism - Lasagna Master.

leap

A solution to the Leap exercise on Exercism, which involves determining if a given year is a leap year based on specific rules. The solution uses simple conditional logic to check divisibility and handles edge cases correctly. See: Exercism - Leap.

logs-logs-logs

A solution to the Logs, Logs, Logs exercise on Exercism. This exercise involves identifying applications based on specific Unicode characters in log entries, replacing characters in logs, and validating log lengths. See: Exercism - Logs, Logs, Logs.

luhn

A solution to the Luhn exercise, implementing the Luhn algorithm for validating credit card numbers.
See: Exercism - Luhn.

meteorology

A solution to the Meteorology exercise on Exercism, representing meteorological data such as temperature, wind speed, and humidity, with formatted string output. See: Exercism - Meteorology.

need-for-speed

A solution to the Need For Speed exercise, simulating a racing car with different speeds and fuel levels.
See: Exercism - Need For Speed.

nucleotide-count

A solution to the Nucleotide Count exercise on Exercism, which involves counting occurrences of each nucleotide ('A', 'C', 'G', 'T') in a given DNA sequence. The solution also validates the input to ensure it contains only valid nucleotide characters.
See: Exercism - Nucleotide Count.

pangram

A solution to the Pangram exercise, checking if a string contains every letter of the English alphabet at least once.
See: Exercism - Pangram.

party-robot

A solution to the Party Robot exercise, practicing string formatting and control flow.
See: Exercism - Party Robot.

prime-factors

A solution to the Prime Factors exercise on Exercism, which computes the prime factorization of an integer. The function identifies all prime factors and returns them in ascending order. See: Exercism - Prime Factors.

raindrops

A solution to the Raindrops exercise, implementing string manipulation based on divisibility rules.
See: Exercism - Raindrops.

resistor-color

A solution to the Resistor Color exercise on Exercism, which involves determining the numeric value associated with resistor color bands. This exercise helps practice working with slices, maps, and basic control flow in Go. See: Exercism - Resistor Color.

resistor-color-duo

A solution to the Resistor Color Duo exercise from the Exercism Go track. This exercise calculates the resistance value of a resistor based on its first two color bands, using a standard set of resistor color codes. See: Exercism - Resistor Color Duo.

reverse string

A solution to the Reverse exercise, which involves reversing a string while handling multi-byte Unicode characters properly. See: Exercism - Reverse.

roman-numerals

A solution to the Roman Numerals exercise, converting integers to Roman numeral representations using a greedy algorithm.
See: Exercism - Roman Numerals.

rotational-cipher

A solution to the Rotational Cipher exercise from the Exercism Go track. This exercise implements a Caesar cipher that shifts each letter in the input string by a specified key, wrapping around within the alphabet. Non-alphabetic characters remain unchanged. See: Exercism - Rotational Cipher.

scrabble-score

A solution to the Scrabble Score exercise, calculating word scores based on letter values.
See: Exercism - Scrabble Score.

sieve

A solution to the Sieve exercise on Exercism, implementing the Sieve of Eratosthenes algorithm to find all prime numbers up to a given limit. See: Exercism - Sieve.

simple-cipher

A solution to the Simple Cipher exercise, implementing Caesar, Shift, and Vigenère ciphers for encoding/decoding text.
See: Exercism - Simple Cipher.

sorting

A solution to the Sorting Room exercise on Exercism, which involves implementing utility functions to describe numbers, handle interfaces like NumberBox and FancyNumberBox, and process inputs of varying types. See: Exercism - Sorting Room.

strain

A solution to the Strain exercise on Exercism, which involves filtering slices based on a predicate function. This exercise demonstrates the use of Go's generics to implement flexible and reusable filtering functions. See: Exercism - Strain.

triangle

A solution to the Triangle exercise on Exercism, determining the type of a triangle (equilateral, isosceles, scalene, or not a triangle) based on the lengths of its sides. See: Exercism - Triangle.

two-fer

A solution to the Two Fer exercise, focusing on functions and string interpolation.
See: Exercism - Two Fer.

vehicle-purchase

A solution to the Vehicle Purchase exercise, making decisions based on user input.
See: Exercism - Vehicle Purchase.

welcome-to-tech-palace

A solution to the Welcome to Tech Palace exercise, practicing text formatting.
See: Exercism - Welcome to Tech Palace.

word-count

A solution to the Word Count exercise on Exercism. This exercise involves parsing a given phrase, normalizing it, and counting the frequency of each word. Handles spaces, punctuation, and special cases like internal single quotes within words. See: Exercism - Word Count

Useful Resources

About

A repository collecting my Go code while learning it

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published