Bubblegum, 98 bytes
00000000: 6672 6f6d 206d 6174 6820 696d 706f 7274 from math import
00000010: 2066 6163 746f 7269 616c 2061 7320 4623 factorial as F#
00000020: 0a74 7279 3a6e 3d69 6e74 2869 292d 313b .try:n=int(i)-1;o=n*1;
00000030: 6f3d 6e2a 2846 286e 2925 2d7e 6e3d 3d6e o=n*(F(n)%-~n==n)
00000040: 290a 6578 6365 7074 3a6f 3d73 756d 286d ).except:o=sum(mapm
00000050: 6170 2869 6e74 2c69 2e73 706c 6974 2829 ap(int,i.split()
00000060: 2929 ))
Try it online! Try it online! (Note that the online interpreter takes input in xxd format)
Bubblegum is really good at three things:
Compressing large outputs,
Testing for primality, and
Adding a sequence of numbers.
It's really really really bad at everything else.
Bubblegum, 98 bytes
from math import factorial as F#
try:n=int(i)-1;o=n*(F(n)%-~n==n)
except:o=sum(map(int,i.split()))
Try it online! (Note that the online interpreter takes input in xxd format)
Bubblegum is really good at three things:
Compressing large outputs,
Testing for primality, and
Adding a sequence of numbers.
It's really really really bad at everything else.
Bubblegum, 98 bytes
00000000: 6672 6f6d 206d 6174 6820 696d 706f 7274 from math import
00000010: 2066 6163 746f 7269 616c 2061 7320 4623 factorial as F#
00000020: 0a74 7279 3a6e 3d69 6e74 2869 292d 313b .try:n=int(i)-1;
00000030: 6f3d 6e2a 2846 286e 2925 2d7e 6e3d 3d6e o=n*(F(n)%-~n==n
00000040: 290a 6578 6365 7074 3a6f 3d73 756d 286d ).except:o=sum(m
00000050: 6170 2869 6e74 2c69 2e73 706c 6974 2829 ap(int,i.split()
00000060: 2929 ))
Try it online! (Note that the online interpreter takes input in xxd format)
Bubblegum is really good at three things:
Compressing large outputs,
Testing for primality, and
Adding a sequence of numbers.
It's really really really bad at everything else.
Bubblegum, 98 bytes
from math import factorial as F#
try:n=int(i)-1;o=n*(F(n)%-~n==n)
except:o=sum(map(int,i.split()))
Try it online! (Note that the online interpreter takes input in xxd format)
Bubblegum is really good at three things:
Compressing large outputs,
Testing for primality, and
Adding a sequence of numbers.
It's really really really bad at everything else.