1 / 9

Component 4: Introduction to Information and Computer Science

Component 4: Introduction to Information and Computer Science. Unit 5: Overview of Programming Languages, Including Basic Programming Concepts Lecture 2.

Download Presentation

Component 4: Introduction to Information and Computer Science

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Component 4: Introduction to Information and Computer Science Unit 5: Overview of Programming Languages, Including Basic Programming Concepts Lecture 2 This material was developed by Oregon Health & Science University, funded by the Department of Health and Human Services, Office of the National Coordinator for Health Information Technology under Award Number IU24OC000015.

  2. Unit 5 Objectives Define the purpose of programming languages. Define the different types of programming languages. Explain the continuum of programming languages from machine code and assembly languages through scripting languages and high level structured programming languages. Explain the compiling and interpreting process for computer programs. Use the following components of programming languages to build a simple program: variables, loops and conditional statements. Introduce additional programming concepts such as objects and modularity. Health IT Workforce Curriculum Version 2.0/Spring 2011

  3. Executing Programs • Computers execute machine code • Assemblers translate assembly language into machine code • How are the higher level languages transformed into machine code? Health IT Workforce Curriculum Version 2.0/Spring 2011

  4. Compiled Languages • Program written and stored in a file(s) • Compiler transforms the program into machine code • Machine code is stored in a new file and can be executed Health IT Workforce Curriculum Version 2.0/Spring 2011

  5. Compiled Languages, Contd. • Each type of computer must have its own compiler • Every program must be compiled separately for each computer • Examples: C, C++, FORTRAN Health IT Workforce Curriculum Version 2.0/Spring 2011

  6. Interpreted Languages • Interpreted languages are compiled and executed at the same time • Each line is compiled to machine code • If no errors, executes and goes to next line • If errors, program ends 0011010001011 1001011111010 Health IT Workforce Curriculum Version 2.0/Spring 2011

  7. Interpreted Languages, Contd. • The interpreter is unique to each type of computer • Any program can be interpreted and run on any computer with an interpreter • Many scripting languages are interpreted • Examples: • BASIC, Perl, MUMPS (early version) Health IT Workforce Curriculum Version 2.0/Spring 2011

  8. Hybrid Approach • Some languages are compiled to virtual machine code then interpreted to machine code • Combines speed of compiled language with portability of interpreted language • Examples: • Java, Python Health IT Workforce Curriculum Version 2.0/Spring 2011

  9. Example: Java JVM • Java programs are compiled to byte code • The Java Virtual Machine (JVM) runs the byte code • JVM unique to each type of computer • Byte code is portable JVM Health IT Workforce Curriculum Version 2.0/Spring 2011

More Related