An open API service indexing awesome lists of open source software.

https://github.com/chrisdotslash/fizz-buzz-challenge

FizzBuzz: Classic live coding interview question written in JavaScript
https://github.com/chrisdotslash/fizz-buzz-challenge

coding-challenge coding-challenges coding-interviews fizz-buzz fizzbuzz fizzbuzz-javascript

Last synced: 7 months ago
JSON representation

FizzBuzz: Classic live coding interview question written in JavaScript

Awesome Lists containing this project

README

          

# FizzBuzz coding challenge in JavaScript

[View demo](https://replit.com/@chriseborowski/FizzBuzz) • [Report bug](https://github.com/chriseborowski/fizz-buzz-challenge) • [Request feature](https://github.com/chriseborowski/fizz-buzz-challenge) • [DM author](https://twitter.com/chriseborowski)

![Live demo](https://github.com/chriseborowski/fizz-buzz-challenge/blob/main/fizzbuzz-live-demo.png)

## About

Hailed as a canonical live coding interview question, FizzBuzz is here, written in JavaScript!

**Sample prompt:**

*Write a program that prints the numbers from 1 to 100. But for multiples of three print "Fizz" instead of the number and for the multiples of five print "Buzz". For numbers which are multiples of both three and five print "FizzBuzz"* ([source: CodingHorror](https://blog.codinghorror.com/why-cant-programmers-program/))

For a live demo of the project on Replit, click [here](https://replit.com/@chriseborowski/FizzBuzz).

For a video clip demonstrating how the code works, click [here](https://twitter.com/chriseborowski/status/1671219941960187916).

## Getting started

1. Clone the repository to your machine

`git clone https://github.com/chriseborowski/fizz-buzz-challenge.git`

2. Run the code in your preferred code editor (e.g., VSCode) or Terminal/Bash window (sample code below)

`node fizzbuzz.js`

Edit or adjust the code according to your needs.

## License

Distributed under the MIT License. See `license.txt` for more information.

## Contact

Chris Borowski

Follow me **@chriseborowski** on [GitHub](https://github.com/chriseborowski) • [Twitter](https://twitter.com/chriseborowski) • [T2](https://t2.social/chriseborowski) • [LinkedIn](https://www.linkedin.com/in/chriseborowski) • [Linktree](https://linktr.ee/chriseborowski) (all links)

Project repository link: [FizzBuzz coding challenge](https://github.com/chriseborowski/fizz-buzz-challenge)