ict - programming
DESCRIPTION
TRANSCRIPT
![Page 1: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/1.jpg)
PROGRAMMING
Program Development
![Page 2: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/2.jpg)
Learning Outcomes
• Apply program development phases to solve problems• Develop a program
![Page 3: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/3.jpg)
Situation
• Your younger brother has a problem with a basic mathematic operations like addition, subtraction, multiplication, and division. Your parents ask you to develop one simple system using Visual Basic to help your brother.
• Your system should have function button to calculate the additional, subtraction, multiplication, and division for at least two integer numbers
![Page 4: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/4.jpg)
Programming Development Phase
1. Problem Analysis2. Program Design3. Coding4. Testing and Debugging5. Documentation
![Page 5: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/5.jpg)
1. Problem Analysis
• What the problem?• What the input, process, and output?• What the formula on how to calculate
the mathematic operations?
![Page 6: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/6.jpg)
2. Program Design
• Write the pseudo code• Write flow chart• Design user interface
![Page 7: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/7.jpg)
Pseudo code
PROGRAM Mathematic_OperationsREAD the first numberREAD the second numberREAD command button Add
CALCULATE the sum of number 1 and number 2PRINT the answer for Addition
END PROGRAM
![Page 8: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/8.jpg)
Flow ChartSTART
READ number 1 & 2
CALCULATE
STOP/END
PRINT the answer
![Page 9: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/9.jpg)
User Interface
![Page 10: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/10.jpg)
3. Coding
• SCRIPTING
![Page 11: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/11.jpg)
Coding
‘formula for additional (internal documentation)
Private Sub cmdAdd_Click()Dim Number1, Number2 As Integer Number1 = txtNumber1.Text Number2 = txtNumber2.Text txtSum = Number1 + Number2End Sub
![Page 12: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/12.jpg)
4. Testing and Debugging
• RUN & COMPILING
![Page 13: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/13.jpg)
5. Documentation
• Internal Documentation• External Documentation
![Page 14: Ict - Programming](https://reader035.vdocument.in/reader035/viewer/2022081907/548ff349b4795900698b45da/html5/thumbnails/14.jpg)
Exercises
• Modify the additional formula to use for subtractions, multiplication and division.