Programming For Beginners.pdf - Google Drive

1 downloads 8 Views 3MB Size Report
Page 3 of 145. The Problem Analysis–Coding–Execution Cycle. • Understand the Overall problem. • Understand probl
‫محمد إبراهيم الدسوقى‬ ‫محاضر بكلية هندسة و علوم الحاسب – قسم نظم المعلومات‬ ‫جامعة سلـــمان بن عبد العزيز ‪ -‬السعودية – محافظة الخرج‬ ‫‪Email : [email protected]‬‬

What Is Programming and Program Development Life Cycle ? •

Programming is a process of problem solving



Step 1: Analyze the problem – Outline the problem and its requirements – Design steps (algorithm) to solve the problem



Step 2: Implement the algorithm – Implement the algorithm in code – Verify that the algorithm works



Step 3: Maintenance – Use and modify the program if the problem domain changes

Algorithm: – Step-by-step problem-solving process 2

The Problem Analysis–Coding–Execution Cycle •

Understand the Overall problem



Understand problem requirements – Does program require user interaction? – Does program manipulate \n"; }

88

Nested Loops •

Example : Write a program that prints out the following pattern.

* ** *** **** ***** ****** for (int i = 1; i