Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function test(x) {
- var result = '';
- if (x!== undefined && typeof(x)==='number') {
- if (x % 5===0) {
- result = result + 'fizz';
- }
- if (x % 3===0) {
- result = result + 'buzz';
- }
- }
- return result;
- }
Add Comment
Please, Sign In to add comment