@DJMcMayhem Thanks, I'll accept that when I'm allowed to. How can I make it ignore the first and third lines? (don't include that in the answer as it's only relevant here)
Python 2, 447 bytes
import re,sys
def f(b,r,a,i,n,f,u,c,k):
d,e,g,m=[0]*30000,0,0,''
for n in re.finditer('|'.join(r'(?P<%s>%s)'%m for m in[(j,re.escape(l))for j,l in zip('rlidoswen',[r,a,i,n,f,u,c,k,'.'])]),b):
m+=' '*g+{'r':'e+=1','l':'e-=1','i':'d[e]+=1','d':'d[e]-=1','o':'sys.stdout.wr...
{"success":"failed","errors":[[{"LanguageID":0,"PhraseID":null,"IsHtmlText":true,"Phrase":null,"IsMock":false,"IsToDo":true,"Language":null,"PreformattedText":"Please check the box or enter the text seen above.","Args":[],"IsEmpty":false}]]}
but that snippet removes the last 15 characters of each line, if you want to remove the last 15 characters of all of input, then use this: sed ':a;$!N;ta;s/.\{15\}$//'
I was wondering if anyone could help me a with a simple fastest-code challenge. I want to write a challenge to take the product of an array of complex numbers
the problems are a) timing it and b) giving the input
Bash, 120 112 106 bytes
-8 bytes because wget is smart enough to redirect HTTP to HTTPS when necessary
-6 bytes thanks to another sed suggestion from Cows quack
wget codegolf.stackexchange.com/users/$1 2>y
cat $1|sed '6!d'|cut -c 13-|cut -d '&' -f1|sed 's/.\{15\}$//'
No TIO link since the T...
Python's random number generator is pretty simple once you wrap your head around it. I still haven't completely reversed it though, since the first key value is just assumed to be 0 rather than actually being calculated (it works for some reason though?)
Double JavaScript, 318 bytes
I'm not sure if that's allowed, I couldn't do it using the JavaScript interpreter once. It's similar to use eval() but instead I'm using the interpreter twice:
`\`\\x${0xA*0xA&0xC}${0xA&0xC}\\x${0xA*0xF&0xF}${0xB*0xF&0xF}\\x${0xA*0xF&0xF}C\\x${0xA*0xF&0xF}C\\x${0x...
@JohnDvorak In PowerShell you can condition on anything, too, but we have a wider selection -- 0, $null, empty string, empty array, and $false ... everything else is truthy
if input can't be empty, then /[13579]/d will work in sed, it outputs an empty string for a truthy testcase, or does nothing to the input if it is falsey
@StepHen I don't know, your sequence language will probably end up beating mine because I noticed that mine isn't really sequence-specialized :P It just has a bit more control flow that something like 05AB1E