Jump to content

Write language name in 3D ASCII: Difference between revisions

m
→‎simpler, shorter: added whitespace.
m (→‎block characters: uppercased an acronym, added whitespace to a link.)
m (→‎simpler, shorter: added whitespace.)
Line 2,333:
<br>the output doesn't have extraneous leading blanks,
<br>the output doesn't have trailing blanks,
<br>the input text can be any consistent non-blank character except the forward slash &nbsp; (<big>'''/'''</big>) &nbsp; or backward slash &nbsp;(<big>'''\'''</big>).
<lang rexx>/*REXX pgm draws a "3D" image of text representation; (any charcharacter except / & and \). */
#=7; @.1 = '@@@@ '
@.2 = '@ @ '
@.3 = '@ @ @@@@ @ @ @ @ '
@.4 = '@@@@ @ @ @ @ @ '
@.5 = '@ @ @@@ @ @ '
@.6 = '@ @ @ @ @ @ @ '
@.7 = '@ @ @@@@ @ @ @ @ '
do j=1 for #; x=left(strip(@.j),1) /* [↓] display the (above) text lines.*/
$.1 = changestr( " " , @.j, ' ' ) ; $.2 = $.1
$.1 = changestr( x , $.1, '///' )" "
$.2 = changestr( x , $.2, '\\\' )" "
$.1 = changestr( "/ ", $.1, '/\' )
$.2 = changestr( "\ ", $.2, '\/' )
do k=1 for 2; say strip(left('',#-j)$.k,'"T'") /*the LEFT BIF does indentation.*/
end /*k*/ /* [↓] display a line and its shadow.*/
end /*j*/ /*stick a fork in it, we're all done. */</lang>
'''output''' &nbsp; when using the default input:
<pre>
Cookies help us deliver our services. By using our services, you agree to our use of cookies.