-(void)fizzbuzz { int i = 1;int t = 3; int f = 5;int h = 101; int z = 0;
// here we do a for loop using i and incrementing it until it's equal to z
for (i = i; i < h; i++)
{
/* we check if both i/t is equal to z and if i/f is equal to z
if both are true we log fizzbuzz in the console */
if (i % t == z && i % f == z)
{
NSLog(@"FizzBuzz");
}
//check if i/t = z and log
else if (i % t == z)
{
NSLog(@"Fizz");
}
//check if i/f = z and log
else if (i % f == z)
{
NSLog(@"Buzz");
}
// if none of them are true we just act like we're learning to count
else
{
NSLog(@"%d", i);
}
}
}