#include <stdio.h>
#include <stdint.h>
typedef uint8_t mytype;

void print_bitmask(mytype a) {
	int i;
	for (i=0;i<sizeof(mytype) * 8;i++) {
		if(a& (1<<i)) putchar('1');
		else          putchar('0');
		if((i+1)%4 ==0) putchar(' ');
	}
}

#define print(s) do { \
	s; \
	printf("%10s\t", #s); \
	printf("a: "); print_bitmask(a); \
	printf(" b: "); print_bitmask(b); \
	printf(" a: %d b: %d\n", a,b); \
	} while (0)

int main(void) {
	mytype a = 5;
	mytype b = 25;
	
	print(a=5; b=25);
	print(a ^= b);	
	print(b ^= a);	
	print(a ^= b);	
	return 0;
}
