Posts by Hakerh400
Haskell, 29 bytes import Text.Printf printf"%b" Try it online! Without builtins: Haskell, 37 bytes f n|n<2=[n]|0<1=f(div n 2)++[rem n 2] Try it online!
JavaScript (Node.js), 36 bytes f=a=>a?.map?[a.length,...f(a[0])]:[] Try it online!
JavaScript (Node.js), 86 bytes f=(a,b=2,c=(a,b=2)=>a-b?a%b&&c(a,b+1):1,d=a=>c(++a)?a:d(a))=>!c(b)|d(b)-b<a?f(a,b+1):b Try it online!
???, 268 bytes !(115,114,101,98,98,111,82,32,100,110,97,32,115,112,111,67)0|2.~(0,0). 1|0|5.~#.~(0,1).~(0,2)0|4.~#.*(2,0,~(0,5),~(0,2)).~(0,1)-{0|5.~#.~(0,0 ,~(0,1))(0,0,~(0,1)).~#.~(0,~(0,0,2))...
Haskell, 45 bytes foldl(\a b->zipWith((-).(*b))(0:a)$a++[0])[1] Try it online! Uses the "highest power first" convention. Sometimes multiplies the polynomial by $(-1)$.
- ← Previous
- 1
- 2
- 3
- Next →