#include <stdio.h>
int main()
{
int start;
int end;
int step_size;
printf("Count down start?\n");
scanf("%d",&start);
printf("Count down end?\n");
scanf("%d",&end);
printf("Step size?\n");
scanf("%d",&step_size);
// Perform count down
printf("%d", start);
for (int i = start - step_size; i >= end; i -= step_size)
{
printf(", %d", i);
}
return 0;
}
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter