mirror of
				https://github.com/coolaj86/fizzbuzz.git
				synced 2024-11-16 17:29:04 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			14 lines
		
	
	
		
			278 B
		
	
	
	
		
			JavaScript
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			14 lines
		
	
	
		
			278 B
		
	
	
	
		
			JavaScript
		
	
	
		
			Executable File
		
	
	
	
	
| #!/usr/bin/env node
 | |
| "use strict";
 | |
| var sys = require('sys');
 | |
| (function () {
 | |
|   var i, msg;
 | |
|   for (i = 1; i <= 100; i += 1) {
 | |
|     msg = '';
 | |
| 
 | |
|     if (0 === (i % 3)) { msg += "Fizz"; }
 | |
|     if (0 === (i % 5)) { msg += "Buzz"; }
 | |
|     if (msg.length > 0) { console.log(msg); }
 | |
|   }
 | |
| }());
 |