RosettaCodeData/Task/Zhang-Suen-thinning-algorithm/J/zhang-suen-thinning-algorithm-3.j
2023-07-01 13:44:08 -04:00

25 lines
637 B
Text

toASCII=: ' #' {~ '1'&=;._2 NB. convert to ASCII representation
ExampleImg=: noun define
00000000000000000000000000000000
01111111110000000111111110000000
01110001111000001111001111000000
01110000111000001110000111000000
01110001111000001110000000000000
01111111110000001110000000000000
01110111100000001110000111000000
01110011110011101111001111011100
01110001111011100111111110011100
00000000000000000000000000000000
)
toASCII zhangSuen ExampleImg
####### ######
# # ##
# # #
# # #
##### # #
## #
# # ## ## #
# ####