As part of redefining INABIAF the entry now has an equivalent functionality with the generated output. The bugs.md file still has hints on how to get this to use fgets() (for why this is helpful see that file). As a starting point I have the original buffer size increase in schnitzi.alt.c as it would be useful to see how it works and to maybe get the entry to use fgets(). Unfortunately keeping it using gets() is a potential problem but changing it to fgets() is also a potential problem (this goes for all of the entries that use or used gets()). This entry however still uses gets(). The change is the smaller buffer size which means that the entry can not handle big files. The Makefile and README.md now refer to the small buffer size.
53 lines
2.2 KiB
C
53 lines
2.2 KiB
C
#include <stdio.h>
|
|
int r=0,x,y=0, /*
|
|
nt /
|
|
c
|
|
lx /\ / \ /|\ /|\
|
|
u, \/ \\/ \-/ \ /
|
|
dn ]
|
|
e= ||| /|\ /\ /\ = p p
|
|
0 \/ \ / ||| \/ f f f r r
|
|
<, tw t s s i i
|
|
sy || /|\ /\ i eh e e c n n
|
|
t= /- \ / ||| n li l e a t t
|
|
d0 ||| t ll l {< k n f f
|
|
i, || /|\ /|\ (e s ( fr ( f ( (
|
|
o _ ||\ \ / \-/ tu s( t usw o; i s ( " "
|
|
. || - / c [[ tg rv [th rx=f t " % \
|
|
h mh111 de{l) +di (+'( d+% c n+
|
|
> aa000 itte; > +il x+ n inc " "+
|
|
/ ir000[ns[nytyrrne<=)'<xn," , );
|
|
*/ n = 0 ;
|
|
main ( ) {
|
|
char v [
|
|
100 ] , s;
|
|
int t[100 ] ,
|
|
u[100 ] ; u
|
|
[ 0
|
|
]=ftell(stdin ) ;
|
|
while(gets (v ) )
|
|
{t [ r ]=
|
|
strlen (
|
|
v);y=
|
|
t[ r ]
|
|
>y ? t [
|
|
r ] : y;
|
|
u[++r ] =
|
|
ftell(stdin ) ; }
|
|
while ( n
|
|
< y )
|
|
{for(x=0 ; x
|
|
<r;x++) { s
|
|
=' ' ;
|
|
if(n< t [
|
|
x ] ) {
|
|
fseek(stdin ,u [ x ]
|
|
+n , 0 ) ;
|
|
scanf("%c", &
|
|
s )
|
|
; }
|
|
printf("%c", s )
|
|
; }
|
|
printf("\n"); n
|
|
++ ; } }
|