The fizzbuzz problem

The fizzbuzz problem takes it name from a game where the players take turns, going clockwise in a circle, counting upwards from 1: that is, 1, 2, 3, etc.

Except that there are three rules:

Recast as a programming problem, fizzbuzz goes like this:

Write a function that takes an single integer parameter, and returns a string. The parameter x is an integer greater than or equal to 1. The return value should be either the number x formatted as a string, or the word “fizz”, “buzz”, or “fizzbuzz” as appropriate.

For example: