I have not tested it, but the following code should be the most compact form of
generating a binary character string from a byte value (Problem #6):
MVC OBUFF,IBYTE
MVC OBUFF+1(7),WORK8
NC OBUFF,=X'8040201008040201'
MVO WORK5,OBUFF(4)
MVC OBUFF(4),WORK5
TR OBUFF,=C'011111111'
IBYTE DC B'01110101' Sample input value
WORK5 DC X'0000000000'
OBUFF DS CL8 Output value
Summary of storage requirements:
36 Instructions
17 Literals
1 Input Buffer
5 Work Area
8 Output Area
67 Total Bytes
6 Total Instructions
John P Baker
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html