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

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

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 TO SALARY. MOVE 2000 TO OVERTIME. ADD OVERTIME TO SALARY

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

6 MOVE 7000 TO EXTRA MOVE TO SALARY. MOVE 2000 TO OVERTIME. MOVE 1500 TO BONUS ADD OVERTIME BONUS TO SALARY EXTRA 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

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

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

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

13 SUBTRACT

14 SUBTRACT WITHDRAW FROM TOTAL SUBTRACT 45 FROM TOTAL TOTAL WITHDRAWAL TOTAL TOTAL

15 SUBTRACT SUBTRACT PAY-M1 PAY-M2 FROM DEBT DEBTPAY-M DEBT 3000 PAY-M2

16 SUBTRACT

17 SUBTRACT PAY-M1 PAY-M2 FROM DEBT GIVING NEW-DEBT DEBTPAY-M 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 DEBTPAY-M NEW-DEBT 3000 PAY-M2 (Edited PICTURE)

19 MULTIPLY

20 MULTIPLY 0.07 BY PRICE 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 PRICE PRICE 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 PRICE PRICE 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 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 M PICTURE 9. DIVIDE 5 TO 23 GIVING N REMAINDER M. 4 N 3 M

36 DIVIDE REMAINDER 01 N PICTURE M PICTURE 9V9(3). DIVIDE 5.1 TO 23.5 GIVING N ROUNDED REMAINDER M. 5 N 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 HEIGHT PIC AGE PIC 99.

73 01 SCOREPICTURE 9(3). 88 GOOD VALUE 75 THRU PASS VALUE 50 THRU 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 PASS VALUE 50 THRU 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 PASS VALUE 50 THRU 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