Kotlinlearncs.online LogoJava
Return to List

Homework: Fizz String

Imported By: Geoffrey Challen
/ Version: 2021.6.0
/ Adapted from CodingBat

Given a non-null, non-empty String, if it starts with "f" return "Fizz". If it ends with "b" return "Buzz". If both conditions are true, return "FizzBuzz". In all other cases, return the String unchanged.