Computer Fundamentals Lecture 10 Software Programming  and Development
Creating Computer Programs
What Is a Computer Program? <ul><li>Computer programs </li></ul><ul><ul><li>Also called software </li></ul></ul><ul><ul><l...
Software Is Stored In Many Files <ul><li>Dynamic link libraries </li></ul><ul><ul><li>Partial executable file </li></ul></...
Hardware/Software Interaction <ul><li>Program execution </li></ul><ul><ul><li>Software executes at the CPU level </li></ul...
Hardware/Software Interaction <ul><li>Machine code </li></ul><ul><ul><li>Recall that computers think in binary </li></ul><...
Hardware/Software Interaction <ul><li>Compiler </li></ul><ul><ul><li>Creates an executable file </li></ul></ul><ul><ul><ul...
Planning a Computer Program <ul><li>Plans </li></ul><ul><ul><li>The steps to solve a problem </li></ul></ul><ul><ul><li>De...
Planning a Computer Program <ul><li>Input-processing-output (IPO) charts </li></ul><ul><ul><li>Determines what is needed <...
How Programs Solve Problems <ul><li>Program control flow </li></ul><ul><ul><li>Order program statements are executed </li>...
How Programs Solve Problems <ul><li>Heuristic </li></ul><ul><ul><li>Set of steps </li></ul></ul><ul><ul><li>Solution is us...
Structured Programming <ul><li>Building programs out of small modules </li></ul><ul><li>Creates easy to read code </li></u...
Structured Programming <ul><li>Sequence structure </li></ul><ul><ul><li>Describes the flow of the program </li></ul></ul><...
Object Oriented Programming <ul><li>Also known as OOP </li></ul><ul><li>Enhances structured programming </li></ul><ul><li>...
Object Oriented Programming <ul><li>Code reuse </li></ul><ul><ul><li>Code used in many projects </li></ul></ul><ul><ul><li...
Programming Languages
Programming Languages <ul><li>Used to generate source code </li></ul><ul><li>Avoids using machine code </li></ul><ul><li>H...
Language Categories <ul><li>First generation language </li></ul><ul><ul><li>Machine languages </li></ul></ul><ul><ul><li>W...
Language Categories <ul><li>Third generation languages (3GL) </li></ul><ul><ul><li>First higher level language </li></ul><...
Web Development Languages <ul><li>Hyper Text Markup Language (HTML) </li></ul><ul><ul><li>Basis of all web pages </li></ul...
Web Development Languages <ul><li>Extensible Style Sheet Language (XSL) </li></ul><ul><ul><li>Format and displays XML docu...
Web Development Languages <ul><li>Web authoring environments </li></ul><ul><ul><li>Reduces tedium for creating pages </li>...
Web Development Languages <ul><li>Scripting languages </li></ul><ul><ul><li>Create dynamic web pages </li></ul></ul><ul><u...
Web Development Languages <ul><li>Active Server Pages (ASP) </li></ul><ul><ul><li>Developed by Microsoft </li></ul></ul><u...
Systems Development Life Cycle
Systems Development Life Cycle <ul><li>Software Development Life Cycle (SDLC) </li></ul><ul><li>Organized way to build pro...
Systems Development Life Cycle <ul><li>Phase 1: Needs Analysis </li></ul><ul><ul><li>Users identify a need </li></ul></ul>...
Systems Development Life Cycle <ul><li>Phase 4: Implementation </li></ul><ul><ul><li>The solution is installed </li></ul><...
Upcoming SlideShare
Loading in …5
×

Lecture 10 software development

500 views

Published on

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Lecture 10 software development

  1. 1. Computer Fundamentals Lecture 10 Software Programming and Development
  2. 2. Creating Computer Programs
  3. 3. What Is a Computer Program? <ul><li>Computer programs </li></ul><ul><ul><li>Also called software </li></ul></ul><ul><ul><li>Are a list of instructions </li></ul></ul><ul><ul><li>Instructions are called code </li></ul></ul><ul><ul><li>CPU performs the instructions </li></ul></ul><ul><ul><li>Three types </li></ul></ul><ul><ul><ul><li>Operating system </li></ul></ul></ul><ul><ul><ul><li>Utility </li></ul></ul></ul><ul><ul><ul><li>Application </li></ul></ul></ul>
  4. 4. Software Is Stored In Many Files <ul><li>Dynamic link libraries </li></ul><ul><ul><li>Partial executable file </li></ul></ul><ul><ul><li>Used to support executable files </li></ul></ul><ul><ul><li>Have .dll extensions </li></ul></ul><ul><li>Help files </li></ul><ul><li>Contain information about the software </li></ul><ul><li>Information is indexed and searchable </li></ul><ul><li>Provides an online manual </li></ul><ul><li>Have a .chm or .hlp extension </li></ul><ul><li>Executable files </li></ul><ul><li>Contain the instructions for the CPU </li></ul><ul><li>Have extensions of .exe, or .com </li></ul><ul><li>Initialization files </li></ul><ul><li>Contain configuration settings for software </li></ul><ul><li>Have a .ini extension </li></ul><ul><li>Modern programs use the registry </li></ul><ul><li>Batch files </li></ul><ul><ul><li>Used to automate tasks </li></ul></ul><ul><ul><li>Hold a series of OS commands </li></ul></ul><ul><ul><li>Have a .bat extension </li></ul></ul>
  5. 5. Hardware/Software Interaction <ul><li>Program execution </li></ul><ul><ul><li>Software executes at the CPU level </li></ul></ul><ul><ul><li>Code to play a sound </li></ul></ul><ul><ul><ul><li>Code generates an interrupt </li></ul></ul></ul><ul><ul><ul><li>CPU tells the sound card to play </li></ul></ul></ul><ul><ul><ul><li>Sound card plays the file </li></ul></ul></ul><ul><ul><li>Programmer creates the code </li></ul></ul><ul><li>Code </li></ul><ul><ul><li>Statements written in a programming language </li></ul></ul><ul><ul><li>Writing code can be tedious </li></ul></ul><ul><ul><ul><li>Code must be perfect </li></ul></ul></ul><ul><ul><ul><li>Order of steps must be exact </li></ul></ul></ul><ul><ul><li>Writing code is quite exciting </li></ul></ul><ul><ul><ul><li>Problems are solved </li></ul></ul></ul><ul><ul><ul><li>New ideas are formed </li></ul></ul></ul>
  6. 6. Hardware/Software Interaction <ul><li>Machine code </li></ul><ul><ul><li>Recall that computers think in binary </li></ul></ul><ul><ul><li>Code is translated into machine code </li></ul></ul><ul><ul><ul><li>CPU executes the machine code </li></ul></ul></ul><ul><ul><li>CPUs have a unique machine code </li></ul></ul><ul><li>Programming languages </li></ul><ul><ul><li>Simplifies the writing of code </li></ul></ul><ul><ul><ul><li>English is used to describe the binary </li></ul></ul></ul><ul><ul><li>Original code is called source code </li></ul></ul><ul><ul><li>Several hundred languages exist </li></ul></ul><ul><li>Compilers and interpreters </li></ul><ul><ul><li>Converts source code into binary </li></ul></ul><ul><ul><ul><li>Allows code to execute </li></ul></ul></ul><ul><ul><li>Checks source code for correctness </li></ul></ul>
  7. 7. Hardware/Software Interaction <ul><li>Compiler </li></ul><ul><ul><li>Creates an executable file </li></ul></ul><ul><ul><ul><li>Contents are called object code </li></ul></ul></ul><ul><ul><li>Executable can run on its own </li></ul></ul><ul><ul><li>Each language has its own compiler </li></ul></ul><ul><ul><li>C++ and Java are compiled languages </li></ul></ul><ul><li>Interpreter </li></ul><ul><ul><li>Runs program one line at a time </li></ul></ul><ul><ul><li>More flexible than compilers </li></ul></ul><ul><ul><li>Slower than compilers </li></ul></ul><ul><ul><li>Always needed to execute program </li></ul></ul><ul><ul><li>Visual Basic and Perl are interpreted </li></ul></ul>
  8. 8. Planning a Computer Program <ul><li>Plans </li></ul><ul><ul><li>The steps to solve a problem </li></ul></ul><ul><ul><li>Describe the expected results </li></ul></ul><ul><ul><li>Programming without a plan is difficult </li></ul></ul><ul><li>Pseudo code </li></ul><ul><ul><li>Natural language statements that resemble code </li></ul></ul><ul><ul><li>Describes what must be done </li></ul></ul><ul><ul><li>Can be written by non programmers </li></ul></ul><ul><ul><li>Programmers develop unique versions </li></ul></ul>
  9. 9. Planning a Computer Program <ul><li>Input-processing-output (IPO) charts </li></ul><ul><ul><li>Determines what is needed </li></ul></ul><ul><ul><li>Input column </li></ul></ul><ul><ul><ul><li>Data inputted by the user </li></ul></ul></ul><ul><ul><li>Processing column </li></ul></ul><ul><ul><ul><li>Pseudo code describing the problem solution </li></ul></ul></ul><ul><ul><li>Output column </li></ul></ul><ul><ul><ul><li>Desired output from the program </li></ul></ul></ul>
  10. 10. How Programs Solve Problems <ul><li>Program control flow </li></ul><ul><ul><li>Order program statements are executed </li></ul></ul><ul><ul><li>Typically executed in order </li></ul></ul><ul><ul><li>Constructs can change the flow </li></ul></ul><ul><ul><ul><li>Decision statements </li></ul></ul></ul><ul><ul><ul><li>Loops </li></ul></ul></ul><ul><li>Algorithm </li></ul><ul><ul><li>Set of steps </li></ul></ul><ul><ul><li>Always leads to a solution </li></ul></ul><ul><ul><li>Steps are always the same </li></ul></ul><ul><ul><li>Flowcharts can describe algorithms </li></ul></ul><ul><ul><ul><li>Structured tool for drawing algorithms </li></ul></ul></ul><ul><ul><li>Algorithms appear in all programs </li></ul></ul>
  11. 11. How Programs Solve Problems <ul><li>Heuristic </li></ul><ul><ul><li>Set of steps </li></ul></ul><ul><ul><li>Solution is usually found </li></ul></ul><ul><ul><li>Solution may not be optimal </li></ul></ul><ul><ul><li>Used when algorithms fail </li></ul></ul><ul><ul><ul><li>Algorithm is nonexistent or too complex </li></ul></ul></ul><ul><ul><li>Appear in more complex applications </li></ul></ul><ul><ul><ul><li>Data mining </li></ul></ul></ul><ul><ul><ul><li>Anti-virus software </li></ul></ul></ul>
  12. 12. Structured Programming <ul><li>Building programs out of small modules </li></ul><ul><li>Creates easy to read code </li></ul><ul><li>Programs are efficient and run fast </li></ul><ul><li>Programming using defined structures </li></ul><ul><ul><li>Several defined structures </li></ul></ul>
  13. 13. Structured Programming <ul><li>Sequence structure </li></ul><ul><ul><li>Describes the flow of the program </li></ul></ul><ul><ul><li>Typically executed in order </li></ul></ul><ul><ul><li>Branching statements allow multiple flows </li></ul></ul><ul><li>Selection statement </li></ul><ul><ul><li>Also called conditional statement </li></ul></ul><ul><ul><li>Performs a true or false test </li></ul></ul><ul><ul><li>Determines which code to execute next </li></ul></ul><ul><li>Repetition statements </li></ul><ul><ul><li>Also called looping structures </li></ul></ul><ul><ul><li>Repeats a section of code </li></ul></ul><ul><ul><li>Until an exit condition is reached </li></ul></ul>
  14. 14. Object Oriented Programming <ul><li>Also known as OOP </li></ul><ul><li>Enhances structured programming </li></ul><ul><li>Intuitive method of programming </li></ul>
  15. 15. Object Oriented Programming <ul><li>Code reuse </li></ul><ul><ul><li>Code used in many projects </li></ul></ul><ul><ul><li>Speeds up program development </li></ul></ul><ul><ul><li>Simplifies program development </li></ul></ul><ul><li>Develops objects </li></ul><ul><ul><li>All real world items are objects </li></ul></ul><ul><ul><li>Contains data about the item </li></ul></ul><ul><ul><li>Contains functionality </li></ul></ul><ul><ul><li>Object encapsulates both into one package </li></ul></ul>
  16. 16. Programming Languages
  17. 17. Programming Languages <ul><li>Used to generate source code </li></ul><ul><li>Avoids using machine code </li></ul><ul><li>Have strict rules of syntax </li></ul><ul><ul><li>Symbols and punctuation have meaning </li></ul></ul><ul><ul><li>Spelling must be exact </li></ul></ul><ul><li>Code is converted into machine language </li></ul>
  18. 18. Language Categories <ul><li>First generation language </li></ul><ul><ul><li>Machine languages </li></ul></ul><ul><ul><li>Written in binary </li></ul></ul><ul><ul><li>Different for every CPU </li></ul></ul><ul><li>Second generation languages </li></ul><ul><ul><li>Assembly languages </li></ul></ul><ul><ul><li>Statements that represent machine code </li></ul></ul><ul><ul><li>Code converted by an assembler </li></ul></ul><ul><ul><li>Still used to optimize video games </li></ul></ul>
  19. 19. Language Categories <ul><li>Third generation languages (3GL) </li></ul><ul><ul><li>First higher level language </li></ul></ul><ul><ul><li>Supports structured and OOP </li></ul></ul><ul><ul><ul><li>Code is reusable </li></ul></ul></ul><ul><ul><ul><li>Code is portable </li></ul></ul></ul><ul><ul><li>Typically written in an IDE </li></ul></ul><ul><ul><li>C/C++ creates games and applications </li></ul></ul><ul><ul><li>Java creates web applets </li></ul></ul><ul><ul><li>ActiveX creates Web and Windows applets </li></ul></ul><ul><li>Fourth generation languages (4GL) </li></ul><ul><ul><li>Easier to use than 3GL </li></ul></ul><ul><ul><li>Coded in a visual IDE </li></ul></ul><ul><ul><li>Tools reduce the amount of code </li></ul></ul><ul><ul><li>Object oriented programming </li></ul></ul><ul><ul><li>Microsoft Visual Studio and Dream Weaver are 4GL IDE </li></ul></ul>
  20. 20. Web Development Languages <ul><li>Hyper Text Markup Language (HTML) </li></ul><ul><ul><li>Basis of all web pages </li></ul></ul><ul><ul><li>Defines web structure using tags </li></ul></ul><ul><ul><li>Easy to learn and use </li></ul></ul><ul><ul><li>Created with a text editor </li></ul></ul><ul><li>Extensible Markup Language (XML) </li></ul><ul><ul><li>Stores data in a readable format </li></ul></ul><ul><ul><li>Looks like HTML </li></ul></ul><ul><ul><li>Allows developers to create tags </li></ul></ul><ul><ul><li>Depends on HTML for formatting </li></ul></ul><ul><li>Extensible HTML (XHTML) </li></ul><ul><ul><li>Newer version of HTML </li></ul></ul><ul><ul><li>Stricter rules </li></ul></ul><ul><ul><li>Based on XML rules </li></ul></ul>
  21. 21. Web Development Languages <ul><li>Extensible Style Sheet Language (XSL) </li></ul><ul><ul><li>Format and displays XML documents </li></ul></ul><ul><ul><li>Rules that dictate formatting </li></ul></ul><ul><ul><li>Create a standard web page </li></ul></ul><ul><li>Extensible HTML Mobile Profile (XHTML MP) </li></ul><ul><ul><li>Initially Wireless Markup Language (WML) </li></ul></ul><ul><ul><li>Creates pages viewable on a handheld </li></ul></ul><ul><li>Cascading Style Sheets (CSS) </li></ul><ul><ul><li>Format HTML, XHTML and XSL </li></ul></ul><ul><ul><li>Applies consistent formatting to all pages </li></ul></ul>
  22. 22. Web Development Languages <ul><li>Web authoring environments </li></ul><ul><ul><li>Reduces tedium for creating pages </li></ul></ul><ul><ul><li>Tools that simplify web site creation </li></ul></ul><ul><ul><li>Macromedia Dream weaver </li></ul></ul><ul><ul><ul><li>Simplifies large sites </li></ul></ul></ul><ul><ul><ul><li>CSS support is exceptional </li></ul></ul></ul><ul><ul><li>Microsoft FrontPage simplifies large sites </li></ul></ul><ul><ul><li>Macromedia Flash creates web animations </li></ul></ul>
  23. 23. Web Development Languages <ul><li>Scripting languages </li></ul><ul><ul><li>Create dynamic web pages </li></ul></ul><ul><ul><ul><li>Change based on user input </li></ul></ul></ul><ul><ul><li>HTML can create static pages </li></ul></ul><ul><ul><li>Page is generated as needed </li></ul></ul><ul><li>JavaScript </li></ul><ul><ul><li>Developed by Netscape </li></ul></ul><ul><ul><li>Works inside of HTML </li></ul></ul><ul><ul><li>Page verification and simple animation </li></ul></ul><ul><ul><li>Based on Java </li></ul></ul>
  24. 24. Web Development Languages <ul><li>Active Server Pages (ASP) </li></ul><ul><ul><li>Developed by Microsoft </li></ul></ul><ul><ul><li>Classic ASP was based on Visual Basic (Script) </li></ul></ul><ul><ul><li>Current version is ASP.NET that supports all .NET languages </li></ul></ul><ul><ul><li>Good at connecting to Microsoft databases </li></ul></ul><ul><ul><li>Runs only on Microsoft servers </li></ul></ul><ul><li>Practical Extraction and Reporting Language (Perl) </li></ul><ul><ul><li>Old UNIX language </li></ul></ul><ul><ul><li>Found on all Windows and Linux servers </li></ul></ul><ul><ul><li>Excellent web scripting language </li></ul></ul><ul><li>Hypertext Pre-Processor (PHP) </li></ul><ul><ul><li>Especially good at connecting to MySQL </li></ul></ul><ul><ul><li>Very popular language </li></ul></ul><ul><ul><li>Runs on UNIX and Windows </li></ul></ul>
  25. 25. Systems Development Life Cycle
  26. 26. Systems Development Life Cycle <ul><li>Software Development Life Cycle (SDLC) </li></ul><ul><li>Organized way to build programs </li></ul><ul><li>Consists of five phases </li></ul>
  27. 27. Systems Development Life Cycle <ul><li>Phase 1: Needs Analysis </li></ul><ul><ul><li>Users identify a need </li></ul></ul><ul><ul><li>Need is clearly defined using tools </li></ul></ul><ul><li>Phase 2: Systems design </li></ul><ul><ul><li>Solution to the need is defined </li></ul></ul><ul><ul><li>Many tools are used </li></ul></ul><ul><ul><li>Prototypes of the solution are built </li></ul></ul><ul><li>Phase 3: Development </li></ul><ul><ul><li>Solution to the problem is built </li></ul></ul><ul><ul><li>Programmers write the solution </li></ul></ul><ul><ul><li>Technical writers document the process </li></ul></ul><ul><ul><li>Solution is continually tested </li></ul></ul>
  28. 28. Systems Development Life Cycle <ul><li>Phase 4: Implementation </li></ul><ul><ul><li>The solution is installed </li></ul></ul><ul><ul><li>Users are converted to the new system </li></ul></ul><ul><ul><li>Trainers are important in this phase </li></ul></ul><ul><li>Phase 5: Maintenance </li></ul><ul><ul><li>IT professionals monitor the product </li></ul></ul><ul><ul><li>Bugs are found and fixed </li></ul></ul><ul><ul><li>New features are added </li></ul></ul>

×