Format/typo check 1996/dalbec
Also since it was my proposed fix to the code (for clang) I decided to change the function name to how I've been doing it: rather than 'cain()' it is now 'pain()'.
This commit is contained in:
1 parent
a728375f14
commit
04889c6384
3 files changed
+21
-20
No files matched your search
@@ -66,9 +66,7 @@ where `a==0`.
|
||||
4. The fact that `main()` is a single expression and so beautifies poorly.
|
||||
|
||||
5. The fact that `main()` is used:
|
||||
|
||||
- to compute powers in modular arithmetic.
|
||||
|
||||
- to recursively call itself in the main loop.
|
||||
|
||||
|
||||
|
||||
+11
-11
@@ -1,16 +1,16 @@
|
||||
int cain(int I, char **O, int O0, int OO, int l)
|
||||
int pain(int I, char **O, int O0, int OO, int l)
|
||||
{
|
||||
return !!I>=I?!I>=I?!!~I>=~I?!~I>=~I?!OO?!I:OO%2?
|
||||
OO=cain(I,O,O0,OO>>!!OO,l),
|
||||
OO=cain(I-!I-!!I,O,OO,OO,l),
|
||||
OO=cain(I-!I-!!I,O,O0,OO,l),
|
||||
OO=pain(I,O,O0,OO>>!!OO,l),
|
||||
OO=pain(I-!I-!!I,O,OO,OO,l),
|
||||
OO=pain(I-!I-!!I,O,O0,OO,l),
|
||||
!(OO-!I||I)?l-1:OO
|
||||
:(OO=cain(I,O,O0,OO>>!!OO,l),
|
||||
!(OO-l+!I||I)?l-1:cain(I-!I-!!I,O,OO,OO,l))
|
||||
:(OO=pain(I,O,O0,OO>>!!OO,l),
|
||||
!(OO-l+!I||I)?l-1:pain(I-!I-!!I,O,OO,OO,l))
|
||||
:(O0+OO)%l
|
||||
:cain(I-I/I-I/I,O,O0,OO+OO/OO,
|
||||
cain(0,O,O0,OO,I-I-I)+I+1?1:printf("%d\n",I-I-I)+fflush(stdout))
|
||||
:cain(I-I-I-I-I,O,I+I-I+I,I,0)
|
||||
:cain(~!!I-!!I,O,atoi(1[O]),1,atoi(0[O]));
|
||||
:pain(I-I/I-I/I,O,O0,OO+OO/OO,
|
||||
pain(0,O,O0,OO,I-I-I)+I+1?1:printf("%d\n",I-I-I)+fflush(stdout))
|
||||
:pain(I-I-I-I-I,O,I+I-I+I,I,0)
|
||||
:pain(~!!I-!!I,O,atoi(1[O]),1,atoi(0[O]));
|
||||
}
|
||||
int main(int I, char **O) { int O0=0,OO=0,l=0; return cain(I,O,O0,OO,l); }
|
||||
int main(int I, char **O) { int O0=0,OO=0,l=0; return pain(I,O,O0,OO,l); }
|
||||
Reference in new issue
Block a user