New answers tagged

0

Burlesque, 9 bytes @AZr\iRuN Try it online! @AZ # Push 'A 'Z r\ # Range from 'A to 'Z concat to string iR # Generate all rotations uN # Insert newlines and pretty-print


2

PowerShell, 64 bytes 1..27+26..1|%{$y=$_ -join(0..25+24..0|%{[char](97+($_+$y)%26)})} Try it online!


1

PowerShell v6+, 59 bytes 1..27+26..1|%{-join(('a'..'z'*3)[$_..($_+25)+($_+24)..$_])} Try it online! Ranges on ranges on ranges.


0

05AB1E, 9 bytes Aā._Ć€ûû» Try it online!


0

W nd, 12 bytes ☺?ûjg:R√½╪▲= Uncompressed: 'Zk:a>Sa(<+26N Explanation 26N % Repeat the following 26 times: 'Zk % The uppercase alphabet :a> % Slice the item after the current counter Sa<+ % Append the items before the current counter % The counter and the index is 1-based, so %...


0

Ruby: 194 bytes require 'io/console' a=[*"a".."z"] c=0 s= loop do i=STDIN.getch if i==a[c] print i s=Time.now if i=='a' else puts "\nFail" exit end if i=='z' puts "\n"+((Time.now-s)*1000).to_s exit end c+=1 end


2

APL (Dyalog), SBCS, 114 153 bytes Using a GUI form to handle keypress events: t←⍬ a←819⌶⎕A f←{⍬≡t:f ⍵⊣t⊢←⎕AI⋄⊃a≠⍞←3⊃⍵:⎕EX⎕A⊣⎕←'Fail'⋄'z'=a~←⊃a:⎕←3⊃⎕AI-t} ⎕DQ⎕A⎕WC'Form'('Event' 'KeyPress' 'f') (Golfed by Adám; I think it would be odd for him to be awarding a bounty for an answer which is now mostly his golf rewrite, so that's here, and my original is ...


0

Burlesque, 16 bytes @AZr@4?*{)' }\mQ Try it online! @AZr@ # Array of A-Z as chars 4?* # 4 of each as strings { )' # Add a newline between each letter }\m # Map for each string of 4 and concatenate Q # Pretty print for newlines instead of "\n"


1

naz, 72 bytes 9a1a2x1v9m2x2v3d2m4a1x1f1a2x3v1o1v1o3v1o1v1o3v1o1v1o3v1o1v1o3v3x2v1l0x1f Explanation (with 0x commands removed) 9a1a2x1v # Set variable 1 equal to 10 (newline) 9m2x2v # Set variable 2 equal to 90 ("Z") 3d2m4a # Set the ...


1

C# (.NET Core), 274 bytes [Without LINQ] Embarrassing number of bytes, but, this is what I got. (x,y,z)=>{var f=new string('#',x+2)+'\n';char[] b=new string(' ',y*x).ToCharArray();Random r=new Random();while(z.Length>0){var d=r.Next(0,y*x);if(b[d]==' '){b[d]=z[0];z=z.Substring(1);}}z=f;for(var j=1;j<y*x+1;)z+=(j%x==1?"#":"")+b[j-1]+(j++%(x)==0?"#\...


Top 50 recent answers are included