by@drafear
AC
1117ms
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}78 48
************************************************ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ************************************************
/tmp/code.c:1:1: warning: data definition has no type or storage class
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
^
/tmp/code.c:1:1: warning: type defaults to 'int' in declaration of 'i' [-Wimplicit-int]
/tmp/code.c:1:3: warning: type defaults to 'int' in declaration of 'w' [-Wimplicit-int]
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
^
/tmp/code.c:1:5: warning: return type defaults to 'int' [-Wimplicit-int]
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
^~~~
/tmp/code.c: In function 'main':
/tmp/code.c:1:5: warning: type of 'h' defaults to 'int' [-Wimplicit-int]
/tmp/code.c:1:13: warning: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
^~~~~
/tmp/code.c:1:13: warning: incompatible implicit declaration of built-in function 'scanf'
/tmp/code.c:1:13: note: include '<stdio.h>' or provide a declaration of 'scanf'
+#include <stdio.h>
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
^~~~~
/tmp/code.c:1:50: warning: implicit declaration of function 'putchar' [-Wimplicit-function-declaration]
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
^~~~~~~
/tmp/code.c:1:61: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
~~~^~~~
/tmp/code.c:1:75: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
i,w;main(h){scanf("%d%d",&h,&w);for(i=++w*h;i--;)putchar(i%w<w-1&i%w>1&i/w<h-1&&i/w?32:i%w?42:10);}
~~~^~~~