Ping Pong

An app that returns a list of numbers with certain numbers replaced by the words ping, pong, and pingpong. Created June 27, 2016.

By Stephanie Gurung and Tony Fabery

Specifications

  • It can count up to the provided number.

    • Example Input: 2
    • Example Output: [1,2]
  • It can replace multiples of 3 with the word "ping".

    • Example Input: 3
    • Example Output: [1,2,"ping"]
  • It can replace multiples of 5 with the word "pong".

    • Example Input: 5
    • Example Output: [1,2,"ping",4,"pong"]
  • It can replace multiples of 15 with the word "pingpong".

    • Example Input: 15
    • Example Output: [..."ping",13,14,"pingpong"]