Code
#include
"stdio.h"
#include
"math.h"
main()
{
int
x,y,z;
FILE
*fp;
fp = fopen("output.dat","w");
for (x = 1; x < 4; x++)
fprintf(fp,"X = %d, ",x);
fprintf(fp,"\n");
for (x = 5; x <= 25; x = x + 5)
fprintf(fp,"X = %d, ",x);
fprintf(fp,"\n");
for (x = 10; x >0; x--)
fprintf(fp,"X = %d, ",x);
fprintf(fp,"\n");
for (x = 0,y = 0; x < 3; y++,x++)
fprintf(fp,"X = %d, ",x+y);
fprintf(fp,"\n");
for (x = 0,y = 10; x < 3 && y > 6; y--,x++)
fprintf(fp,"X = %d, ",x+y);
fprintf(fp,"\n");
for (x = 1; x < 3; x++)
for (y = 1; y < 3; y++)
fprintf(fp,"X = %d,Y = %d, ",x,y);
fprintf(fp,"\n");
for (x = 1; x < 3; x++)
for (y = 1; y < 3; y++)