Presentation on theme: "Program Design and Development"— Presentation transcript:
1 Program Design and Development Facilitation skills offer immediate, practical benefits to any group process. As facilitator, your role is to set the agenda, encourage participation, and guide the pace of the meeting. Use these Dale Carnegie Training® strategies to help make your meeting a success.You can provide handouts to focus the discussion and give attendees a place to record their ideas. If you print handouts with three slides per page, PowerPoint will automatically include blank lines for your meeting participants to take notes.
2 Steps In Program Development Define the ProblemInputs, outputs, processesOutline the solutionMajor stepsMajor subtasksMajor control structures (repetition loops)Major variablesMainline Logic
3 Steps in PD Continued Develop Algorithm Test Algorithm Using pseudocode and flowchartsTest AlgorithmCode into programming languageRun complierDocument and maintain the program
4 Types of Programming Structured/Top Down Programming Modular Design Starting with solution and working into more complex detailsModular DesignGrouping tasks together by functionStructure TheoremElimination of GOTO, replacement with IF-THEN-ELSE
5 Algorithm Definition Lists the steps involved in accomplishing a task Written in simple english and not a formal documentAn algorithm must beLucid, precise, and unambiguousGive the correct solution in all casesEventually end
6 PseudocodeEssentially it is structured english and formalized to look like high-level computer languagesStatements are written in simple englishEach instruction is written on a single lineKeywords and indentations are used to signify control structuresEach set of instructions is written from top to bottom with only one entry and one exitGroups of statements may be formed into modules and that group given a name
7 Program Data Variables, constants, and literals Integer - 16 Real Byte length - 8Short integer - 32Long integer - 64RealFloat – single precisionDouble – double precisionCharacterBoolean
9 Basic Computer Operations A computer can receive information“READ” and “GET”A computer can put out information“PRINT”, “WRITE”, “PUT”, “OUTPUT”, and “DISPLAY”A computer can perform arithmetic actions+ for ADD- for SUBTRACT* for MULTIPLY/ for DIVIDE() for PARENTHESES
10 Basic Computer Options Cont. A computer can assign a value to a variable or memoryTo give an initial value use “INITALISE” or “SET”To assign a value use ‘=‘To keep a piece of information for later use ‘SAVE’ or ‘STORE’A computer can compare variables and select one of two alternative actionsUse of IT THEN and ELSEActually it can select multiple actionsA computer can repeat a group of actionsDOWHILE
11 The Structure Theorem Sequence Selection Repetition The straightforward listing of each stepSelectionThe presentation of a condition and the choice between two actionsRepetitionThe presentation of a set of instructions to be performed repeatedly as long as a condition is true
12 Developing An Algorithm Defining the ProblemInputOutputProcessingUse Meaningful Name
13 Designing an Algorithm Begin with a rough sketch of steps required to solve the problemUse these requirements and structure theorem to establish how the processing will take placeIt is important to not start coding until the necessary steps of defining the problem and designing the solution algorithm have been solved.
14 Checking an Algorithm Choose simple input test case Establish what the expected result should beMake a table of relevant variable namesWalk through the test caseContinue the process until the algorithm is correct
15 Selection Control Structures Used to illustrate a choice between two or more actionsSimple IF statementSimple selection with null false branch (null ELSE statement)Combined selection (IF/AND)Nested IF StatementLinear nested IF statement
16 The CASE StructureAnother way of expressing a linear nested IF statementCan often appear cumbersome
17 Repetition Control Structures Developed because many programs require the same logic to be repeated for several sets of data.ExampleDOWHILE condition p is trueStatement blockENDO
18 DOWHILE Loop Processing The logical condition p is testedIf condition p is found to be true, the statements listed in the statement block will be executed once. Control is returned to the retesting of condition p.If condition p is found to be false, control passes to the next statement after ENDDO and no further processing takes place within the loop.
19 Two important DOWHILE considerations Testing of the condition is done at the beginning of the loop.The only way to terminate the loop is to render the DOWHILE consideration false.
20 REPEAT_UNTIL Structure Is the exact opposite of the DOWHILECondition is checked at the end as opposed to the beginningCounted repetitionQuestion—is any method better than another?