Untitled

mail@pastecode.io avatar
unknown
plain_text
10 months ago
257 B
2
Indexable
Never
#include <iostream>
using namespace std;
int main()
{
	int n = 100;
	int i = 0;
	for (i <= n; i++;)
	if (i % 3 == 0) {
		cout << "fizz";
	}
	if (i % 5 == 0){
		cout << "buzz";
		if ((i % 5 == 0) && (i % 3 == 0)) {
			cout << "fizzbuzz";
		}
}
Leave a Comment