All
Visit the ZMFACC contest web site
for links to source code and output logs plus new problems:
http://z390.sourceforge.net/z390_Mainframe_Assemble_Coding_Contest.htm
1. Congratulations to Werner Rams for first
solution to problem 15 requiring rounding of DP result! Werner used SRP
to solve the problem.
2. I have also posted a second solution for problem 15 which
uses AP and CP to accomplish the rounding.
3. A new problem 17 has been posted requiring
transparent compression and decompression of spaces.
4. I’ve posted 2 additional solutions for problem
12 calculation of standard deviation. Now there are 3 solutions; one
using BFP, one using HFP, and one using just DFP instructions. The DFP
solution proved to be more challenging than expected as the latest POP (at
least for today) is missing the opcode SQXTR corresponding to the existing SQXBR
and SQXR used in the other solutions. As a result I have coded a
substitute SQXTR macro which calls standalone SQXTR CSECT which uses DFP
instructions to perform the square root function using Newton Raphson
method. For the current problem it converged to 34 digit solution in 7
iterations. Suggestions for improving the first guess will help.
Note all 3 solutions produce the same result to 33+ decimal places.
5. I posted a first solution to problem 16 using a
SETBIT macro and a TESTBIT macro to access bit table used to record prime numbers
from 3 to 97 and then retrieve and print them.
All feedback welcome!.
Don Higgins
mailto:don@...
http://don.higgins.net