Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I recently tried the simh emulator pdp11.

The disk image I used can be found on the internet, and instructions for booting it are here.

Presumably it belonged to Dennis Ritchie, as the username is "dmr".

In the /usr/games folder are about 20 games and amusements for wasting expensive computing resources.

One 'game' is called 'bcd'.

If I run it by typing ./bcd, nothing happens. But then the next command I execute gets printed out as ascii art:

 ________________________________________________
/WC -L *                                         |
| ]                                              |
|   ]] ]                                         |
|]                                               |
|111111111111111111111111111111111111111111111111|
|222222222222222222222222222222222222222222222222|
|3]33]3333333333333333333333333333333333333333333|
|444444]44444444444444444444444444444444444444444|
|555555555555555555555555555555555555555555555555|
|]66666666666666666666666666666666666666666666666|
|777777777777777777777777777777777777777777777777|
|888888]88888888888888888888888888888888888888888|
|999999999999999999999999999999999999999999999999|
|________________________________________________|



 ________________________________________________
/LS                                              |
|                                                |
|]                                               |
| ]                                              |
|111111111111111111111111111111111111111111111111|
|2]2222222222222222222222222222222222222222222222|
|]33333333333333333333333333333333333333333333333|
|444444444444444444444444444444444444444444444444|
|555555555555555555555555555555555555555555555555|
|666666666666666666666666666666666666666666666666|
|777777777777777777777777777777777777777777777777|
|888888888888888888888888888888888888888888888888|
|999999999999999999999999999999999999999999999999|
|________________________________________________|

Does anyone know what these represent?

share|improve this question
add comment

1 Answer

up vote 25 down vote accepted

The bcd command formats the output as a punch card, like this one:

enter image description here

From the BSD games man page:

bcd ppt morse - reformat input as punch cards, paper tape or morse code

The ] stands for where the holes would be.

At first glance, it seems to do nothing because it's waiting for input from stdin. Try piping something into it (i.e. command | bcd) to see.

share|improve this answer
1  
Since this appears to be a serious work tool I wonder why it was put in the games folder? –  Dan Neely Dec 17 '12 at 13:54
1  
I don't really think this is a serious work tool; (I think that) in 1979 punch cards weren't used that much. –  Renan Dec 17 '12 at 14:34
1  
@DanNeely To make real punch cards, you need a card punch. printing them is just pretty. –  hildred Dec 2 '13 at 2:41
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.