>Is there any way i can get the system to store an integer in 3 bytes.
Yes, but you would still probably be using at least 4 bytes of storage and why would you want to do this anyway?
>That is i want to read the whole array, by reading 6 values of it at a time.
Hmm, something like this perhaps?
Code:
#include <stdio.h>
int main ( void )
{
int a[12];
int i = 0;
int n = 0;
while ( i < 12 ) {
/* Eew */
i += n = scanf ( "%d %d %d %d %d %d", &a[i], &a[i + 1], &a[i + 2], &a[i + 3], &a[i + 4], &a[i + 5] );
if ( n != 6 )
break;
}
while ( --i >= 0 )
printf ( "%d\n", a[i] );
return 0;
}