All pastes #33553 Raw Edit

Anonymous

public cpp v1 · immutable
#33553 ·published 2005-12-13 19:24 UTC
rendered paste body
#include <stdio.h>int main () {	int answers[9][16]=	{ { 0 },				  { 1, 1 },				  { 1, 4, 4 },				  { 1, 9, 26, 26, 8 },				  { 1, 16, 92, 232, 260, 112, 16 },				  { 1, 25, 240, 1124, 2728, 3368, 1960, 440, 32},				  { 1, 36, 520, 3896, 16428, 39680, 53744, 38368, 12944, 1600, 64 },				  { 1, 49, 994, 10894, 70792, 282248, 692320, 1022320, 867328, 389312, 81184, 5792, 128 },				  { 1, 64, 1736, 26192, 242856, 1444928, 5599888, 14082528, 22522960, 22057472, 12448832, 3672448, 489536, 20224, 256 }				};	int a,b;		while (1) {		scanf("%d %d\n", &a, &b);		if (!a)			return 0;		if (b>=a+a)			printf("0\n");		else			printf("%d\n",answers[a][b]);	}	return 0;}