#include #define MAX(x,y) (((x)>(y))?(x):(y)) struct lint { int len; char *p; }; void lintcat(struct lint *a,struct lint *b) { int k; a->len=b->len; for(k=0;klen;k++) { a->p[k]=b->p[k]; } } int isbigger(struct lint *a,struct lint *b) { int i; if(a->len > b->len) { return 1; } if(a->len < b->len) { return 0; } for(i=0;ilen;i++) { if(a->p[i] > b->p[i]) return 1; if(a->p[i] < b->p[i]) return 0; } return 0; } struct lint lint0={0,""}; int main() { int width; int height; char *p; struct lint *ans; char *buf; while(1) { struct lint max; int i,j; scanf("%d %d\n", &width, &height); if(width==0 && height==0) break; p=(char*)malloc(width*height); ans=(struct lint*)malloc(width*height*sizeof(struct lint)); for(i=0;i