งานนำเสนอกำลังจะดาวน์โหลด โปรดรอ

งานนำเสนอกำลังจะดาวน์โหลด โปรดรอ

Arithmetic Verb Template. ADD MOVE ZERO TO NO. ADD 1 TO NO. 0 1.

งานนำเสนอที่คล้ายกัน


งานนำเสนอเรื่อง: "Arithmetic Verb Template. ADD MOVE ZERO TO NO. ADD 1 TO NO. 0 1."— ใบสำเนางานนำเสนอ:

1 Arithmetic Verb Template

2 ADD

3 MOVE ZERO TO NO. ADD 1 TO NO. 0 1

4 ADD MOVE 10000 TO SALARY. MOVE 2000 TO OVERTIME. ADD OVERTIME TO SALARY 10000 2000 12000

5 ADD MOVE 10000 TO SALARY. MOVE 2000 TO OVERTIME. MOVE 1500 TO BONUS ADD OVERTIME BONUS TO SALARY 10000 2000 1500 13500

6 MOVE 7000 TO EXTRA MOVE 10000 TO SALARY. MOVE 2000 TO OVERTIME. MOVE 1500 TO BONUS ADD OVERTIME BONUS TO SALARY EXTRA 10000 2000 1500 1050013500 7000 ADD

7 ON SIZE ERROR

8 ADD – ON SIZE ERROR ADD OVERTIME TO SALARY ON SIZE ERROR DISPLAY “OVERFLOW” WRITE OUT-REC FROM OVERFLOW-LINE AFTER ADVANCING 1 END-ADD.

9 ADD - GIVING MOVE 45 TO SUM. ADD 20 TO SUM GIVING RESULT. 45 65

10 ADD - GIVING ADD OVERTIME TO BONUS GIVING EXTRA ADD OVERTIME BONUS GIVING EXTRA 4565110 EXTRABONUSOVERTIME (Edited characters)

11 ADD-GIVING ADD OVERTIME BONUS SALARY GIVING TOTAL INCOME. 2000500010000 SALARYBONUSOVERTIME (Edited PICTURE) 17000 INCOMETOTAL

12 ADD - ROUNDED 01 TOTAL PIC 9(5). 01 INCOME PIC 9(5)V99. ADD OVERTIME BONUS SALARY GIVING TOTAL ROUNDED INCOME 20005000.7510000 SALARYBONUSOVERTIME (Edited characters) 1700117000.75 INCOMETOTAL

13 SUBTRACT

14 SUBTRACT WITHDRAW FROM TOTAL SUBTRACT 45 FROM TOTAL 280020000 TOTAL 20000 WITHDRAWAL 17200 TOTAL 19955 TOTAL

15 SUBTRACT SUBTRACT PAY-M1 PAY-M2 FROM DEBT. 100020000 DEBTPAY-M1 16000 DEBT 3000 PAY-M2

16 SUBTRACT

17 SUBTRACT PAY-M1 PAY-M2 FROM DEBT GIVING NEW-DEBT. 100020000 DEBTPAY-M1 16000 NEW-DEBT 3000 PAY-M2 (Edited PICTURE)

18 SUBTRACT – ON SIZE ERROR SUBTRACT PAY-M1 PAY-M2 FROM DEBT GIVING NEW-DEBT ON SIZE ERROR PERFORM OVERFLOW-PARA END-SUBTRACT. 100020000 DEBTPAY-M1 16000 NEW-DEBT 3000 PAY-M2 (Edited PICTURE)

19 MULTIPLY

20 MULTIPLY 0.07 BY PRICE. 10000 PRICE 700 PRICE

21 MULTIPLY MULTIPLY GRADE BY CREDIT. 3.5 GRADE 3 CREDIT 10.5 CREDIT

22 MULTIPLY MULTIPLY QUANTITY BY PRICE-1 PRICE-2 20 QUANTITY 5.25 PRICE-1 7.75 PRICE-2 105.00 PRICE-1 155.00 PRICE-2

23 MULTIPLY

24 MULTIPLY GRADE BY CREDIT GIVING RESULT. 3.5 GRADE 3 CREDIT 10.5 RESULT MULTIPLY GRADE BY CREDIT GIVING RESULT

25 MULTIPLY MULTIPLY QUANTITY BY PRICE-1 PRICE-2 ROUNDED 27 QUANTITY 7.39 PRICE-1 7.39 PRICE-2 199.53 PRICE-1 200 PRICE-2

26 ROUNDED

27 DIVIDE

28 DIVIDE QUANTITY INTO TOTAL-PRICE. 20 QUANTITY 100 TOTAL-PRICE 5

29 DIVIDE DIVIDE 20 INTO TOTAL-PRICE. 100 TOTAL-PRICE 5 DIVIDE 20 INTO TOTAL-PRICE

30 DIVIDE DIVIDE QUANTITY INTO TPRICE-1 TPRICE-2. 5 QUANTITY 100 TPRICE-1 200 TPRICE-2 20 TPRICE-1 40 TPRICE-2

31 DIVIDE

32 DIVIDE GIVING DIVIDE 20 INTO NUMBER GIVING RESULT DIVIDE NUMBER BY 20 GIVING RESULT 100 NUMBER 5 RESULT

33 DIVIDE GIVING ROUNDED DIVIDE NUMBER BY N GIVING RESULT-1 RESULT-2 ROUNDED. DIVIDE N INTO NUMBER GIVING RESULT-1 RESULT-2 ROUNDED. 5 NUMBER 103 N 20.6 RESULT-1 21 RESULT-2

34 DIVIDE REMAINDER

35 01 N PICTURE 99. 01 M PICTURE 9. DIVIDE 5 TO 23 GIVING N REMAINDER M. 4 N 3 M

36 DIVIDE REMAINDER 01 N PICTURE 99. 01 M PICTURE 9V9(3). DIVIDE 5.1 TO 23.5 GIVING N ROUNDED REMAINDER M. 5 N 0.007 M 23.5/5.1 = 4.607

37 COMPUTE

38 COMPUTE RESULT = FIRST + SECOND * THIRD / FOURTH.

39 COMPUTE COMPUTE RESULT1 ROUNDED RESULT2 = FIRST + SECOND * THIRD / FOURTH

40 COMPUTE

41 • ใช้สำหรับการแสดงผลทางจอภาพ หรือ เครื่องพิมพ์ • ใช้เป็น operands ในการคำนวณไม่ได้ • ใช้เป็นตัวเก็บผลของการคำนวณได้ อาทิ อยู่ หลัง GIVING Edited Pictures

42 EDITED PICTURES

43

44

45

46

47

48

49 IF ELSE

50

51 CLASS CONDITION

52 NUMERIC : 0-9 และอาจมีเครื่องหมาย + - ALPHABETIC : อักษรพิมพ์ใหญ่ A-Z พิมพ์เล็ก a- z และที่ว่าง ALPHABETIC-LOWER : อักษรพิมพ์เล็ก a -z และ ที่ ว่าง ALPHABETIC-UPPER : อักษรตัวพิมพ์ใหญ่ A-Z และ ที่ว่าง Class-name : ตัวอักขระที่ได้ประกาศไว้ใน พารา กราฟ SPECIAL-NAME ของ ENVIRONMENT DIVISION

53

54 RELATION CONDITION

55 IF VAL-1 IS EQUAL TO 100 PERFORM EQUAL-100 END-IF IF VAL-1 = 100 PERFORM EQUAL-100 END-IF

56 RELATION CONDITION IF V-1 IS NOT GREATER THAN OR EQUAL V-2 PERFORM NOT-GREATER-EQUAL END-IF IF V-1 NOT >= V-2 PERFORM P-NOT-GREATER-EQUAL END-I

57 SIGN CONDITION

58

59 CONDITION-NAME CONDITION

60

61

62 NESTED IF

63

64

65

66 IF ValidChar DISPLAY "Input OK." ELSE IF LowerCase DISPLAY "NottUpper Case" ELSE IF Vowel Display "Vowel entered." END-IF

67 IF ValidChar DISPLAY "Input OK." ELSE IF LowerCase DISPLAY "NottUpper Case" ELSE IF Vowel Display "Vowel entered." END-IF

68 EVALUATE

69 01 BANKCODE PICTURE 9. …… EVALUATE BANKCODE WHEN 1 PERFORM DEPOSIT-PROCESS WHEN 2 PERFORM WITHDRAW-PROCESS WHEN 3 PERFORM LOAN-PROCESS WHEN OTHER PERFORM OTHER-PROCESS END-EVALUATE.

70 01 CTRY PICTURE X. ….. EVALUATE CTRY WHEN “A” THROUGH “D” PERFORM ABCD-CTRY WHEN “E” PERFORM E-CTRY WHEN OTHER PERFORM OTHER-CTRY END-EVALUATE

71 01 CUS PICTURE X(3). ….. EVALUATE CUS WHEN “NEW” PERFORM NEW-CUS WHEN “OLD” PERFORM OLD-CUS WHEN “VIP” PERFORM VIP-CUS END-EVALUATE

72 01 SPEC. 02 WEIGHT PIC 99. 02 HEIGHT PIC 999. 02 AGE PIC 99.

73 01 SCOREPICTURE 9(3). 88 GOOD VALUE 75 THRU 100. 88 PASS VALUE 50 THRU 74. 88 FAIL VALUE 0 THRU 49. ….. IF SCORE >= 75 AND <= 100 PERFORM GOOD-COUNTER ELSE IF SCORE >= 50 AND <=74 PERFORM PASS-COUNTER ELSE IF SCORE <= 49 PERFORM FAIL-COUNTER END-IF END-IF.

74 01 SCOREPICTURE 9(3). 88 GOOD VALUE 75 THRU 100. 88 PASS VALUE 50 THRU 74. 88 FAIL VALUE 0 THRU 49. ….. IF GOOD PERFORM GOOD-COUNTER ELSE IF PASS PERFORM PASS-COUNTER ELSE IF FAIL PERFORM FAIL-COUNTER END-IF

75 01 SCOREPICTURE 9(3). 88 GOOD VALUE 75 THRU 100. 88 PASS VALUE 50 THRU 74. 88 FAIL VALUE 0 THRU 49. ….. EVALUATE TRUE WHEN GOOD PERFORM GOOD-COUNTER WHEN PASS PERFORM PASS-COUNTER WHEN FAIL PERFORM FAIL-COUNTER END-EVALUATE


ดาวน์โหลด ppt Arithmetic Verb Template. ADD MOVE ZERO TO NO. ADD 1 TO NO. 0 1.

งานนำเสนอที่คล้ายกัน


Ads by Google