DFSORT——前三位不等于0(COMP-3, COMP)
来源:未知 责任编辑:智问网络 发表时间:2013-10-30 11:07 点击:次
Requirement: The first 3 not equal to 0
(1) 01 WS-A PIC S9(09) COMP-3.
Analysis:
S9(09) COMP-3, X'000000', range is 999999999- and 999999999+
Check the 3 leftmost digits, then the range will be 000000999- and 000000999+
There are 2 solutions here:
1. COND=(1,5,PD,LT,-000000999,OR,1,5,PD,GT,+000000999)
2. COND=(1,2,PD,NE,0,AND,3,2,PD,NE,0,AND,5,2,PD,NE,0)
(2) 01 WS-B PIC S9(09) COMP.
Analysis:
S9(09) COMP, X'F0F0F0'
1. COND=(1,2,EQ,X'F0',AND,3,2,EQ,X'F0',AND,5,2,EQ,X'F0')
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 更多>>