

PHP Fizz Buzz solution, any other language solutions?  - obayesshelton
http://www.bayes-shelton.co.uk/index.php/the-fizz-buzz-challenge-in-php/
Hi,<p>I thought I would try and get a collection of examples of the Fizz Buzz challenge solution in different languages. If you have a solution of this challenge it would be great to see then.
======
ColinWright
Have you tested that? I don't code in PHP, but I'm interested to know what it
prints for 15.

~~~
adolfoabegg
It returns 15 Look: <http://codepad.org/wsNKZ25Q>

~~~
obayesshelton
sorry my bad, I have updated it.

~~~
RiderOfGiraffes
I think this should be a good lesson for everyone: don't post code without
testing it.

There's another point here, though. It seems that you're learning PHP
(although in your "About" page you claim that it's one of your skills) so
there's no shame in getting things wrong, but aside from learning that you
really do need to test even apparently trivial things, it's also good practice
to acknowledge other people's contributions, even if only by saying "My thanks
to those who pointed out errors in the original." I wouldn't want explicit
credit by name, but acknowledging other people is good practice. Look at PG's
essays - he regularly thanks people for their feedback.

~~~
obayesshelton
Hi, I would just like to thank RiderOfGiraffes, adolfoabegg and ColinWright
for pointing out a really silly mistake on my part. I should of tested my code
before posting it, This is why I love the development community always great
people to help out.

