Consider the following code segment. for (int k=1; k<=7; k=k+2) { printf("%5i", k); } Which of the following code segments will produce the same output as the code segment above?
a
for (int k=0; k<=7; k=k+2)
{
printf("%5i", k);
}
b
for (int k=0; k<=8; k=k+2)
{
printf("%5i", k+1);
}
c
for (int k=1; k<7; k=k+2)
{
printf("%5i", k+1);
}
d
for (int k=1; k<=8; k=k+2)
{
printf("%5i", k);
}
e
for (int k=0; k<7; k=k+2)
{
printf("%5i", k);
}