Download HISTORY OF PROGRAMMING LANGUAGES LOW

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
HISTORY OF PROGRAMMING LANGUAGES LOW‐LEVEL LANGUAGES a. Machine Language or binary code. e.g. 0100101001 b. Assembly Language. e.g. LDA $DFFF Low‐level languages are microprocessor (CPU) dependent; i.e. the code cannot be used on different types of microprocessors (Pentium, PowerPC, etc). Therefore, low‐level languages are impractical for everyday use. HIGH‐LEVEL LANGUAGES More English‐like; not microprocessor dependent (can be used on different microprocessors). e.g. COBOL, Fortran, BASIC, Pascal, C, C++, Java COMPILERS vs INTERPRETERS Source code is code that you write (text). Object code is binary code that is executed by the computer. An interpreter converts the source code to object code and executes one line at a time (slower). A compiler converts the whole source code to object code first, then executes (faster). Analogy: Using an interpreter (person) to translate a letter in a foreign language one line at a time, as opposed to getting the whole letter translated, then reading it. Interpreter Source code object code Compiler PROGRAMMING APPROACHES a. Linear Oriented Programming Code is written to be executed from top to bottom without procedures or functions. b. Procedure Oriented Programming (POP) The emphasis is on writing procedures or functions to act on data (modular design). e.g. Basic, Pascal, C c. Object‐Oriented Programming (OOP) The emphasis is on writing classes which are templates (blueprints) for the creation of objects. Objects have properties (data) and methods. e.g. C++, Java, Smalltalk OBJECT‐ORIENTED‐PROGRAMMING Visual Basic is semi‐object‐oriented. e.g. picBox.Cls object method e.g. cmdOk.Caption object property We will use a new language – Java – that is entirely OO (object oriented). JAVA  is object‐oriented  is commonly used for internet programming (applets)  is platform independent (mostly), i.e. the same program can be run on Windows, MacOS, Linux, etc.  is interpreted (slower)  is case‐sensitive !