I've made a program to make arrays and their summations, it works but the outputs are not arranged! I wondered what is the problem ?!
#include <stdio.h>
#include <stdlib.h>
#include <conio.h>
int main() {
int numbers1[3],numbers2[3],results[3];
int x,y,z,a,b;
int c;
for ( x=0,y=0,z=0 ; x<=3,y<=3,z<=3 ; x++,y++,z++ ){
a,b=0;
printf("enter your %d number in the first array: ",x+1);
scanf("%d",&a);
printf("enter your %d number in the secod array: ",y+1);
scanf("%d",&b);
numbers1[x]= a;
numbers2[x]= b;
results[x]= a + b;
printf("============================================================");
printf("%d + %d = %d \n", numbers1[x], numbers2[x], results[x]);
}
for( c=0 ; c<=3 ; c++){
printf("%d + %d = %d \n", numbers1[c], numbers2[c], results[c]);
}
system("PAUSE");
return 0;
}