Top Banner

Click here to load reader

Brief History of Computers and Computer Languages

Jan 03, 2016

ReportDownload

Documents

  • Brief History of Computers and Computer Languages

    CSCE106

  • OutlineA brief history of computers {section 1.1}Programming languages {section 1.3}Processing a high-level language program {section 1.4}Professional ethics for computer programmers {section 1.7}

    CSCE106

  • Early ComputersFirst computer invented in the late 1930s to perform mathematical computations.ENIAC, the first large-scale, general purpose electronic digital computer, which was completed in 1946, used to be programmed by connecting hundreds of wires and arranging thousands of switches in a certain way. (Weighed 30 tons & occupied 9x15m2).Dr. John Von Neumann, at Princeton University, in the same year proposed the concept of a stored program computer, and he designed a computer based on this idea. Stored-program computer (Von Neumann architecture) is the basis of today's digital computers.

    CSCE106

  • MicroprocessorMuch smallerMuch more powerfulFigure 1-2 The ENIAC computer (courtesy of U.S. Army Historic Computer Images)Figure 1-3 A lab technician holds a modern microprocessor (photo courtesy of IntelCorporation)Early Computers (contd)Source: Gaddis T. Starting Out With Games and Graphics in C++. Addison Wesley, 2010.

    CSCE106

  • Categories of ComputersMicrocomputers. Minicomputers. Mainframes.Supercomputers.

    Time Sharing (allowing simultaneous access to a single computers resources by a number of users)

    CSCE106

  • Programming LanguagesMachine Language (low-level language)Native tongue of the computerBinary 0s and 1s that specify what to do0010 0000 0000 01001000 0000 0000 01010011 0000 0000 0110Assembly Language: Symbolic encoding of Machine Language:MVI B, 05HLDA 1234HADD BHigh-Level LanguagesResemble human language (C++, C, Pascal, Java)a = a + b;AssemblerCompiler

    CSCE106

  • Processing a High-Level Language ProgramEditor used to enter the programSource program (file.cpp)UNIX vi text editorCompiler translates the source program, producing object program (file.obj) Displays syntax errors (not descriptive)Linker combines object file with other object filesExecutable program (file.exe)Loader copies executable instructions to memory, and directs CPU to begin execution with the first instruction.

    CSCE106

  • Program Processing Diagram (1)

    CSCE106

  • Program Processing Diagram (2)

    CSCE106

  • Processing a High-Level Language Program (contd)An IDE (integrated development environment) is a package that combines a simple editor with a compiler, linker, and loader. IDEs give the developer menus from which to select steps, and if the developer tries a step that is out of sequence, the IDE simply fills in the missing steps automatically.IDEs might simply leave the program in memory; therefore, users must remember to save the source file to disk after every modification before attempting to run the program, to avoid loosing it in case something goes wrong.Examples:C++ Builder, Microsoft Visual C++

    CSCE106

  • Professional Ethics for Computer ProgrammersPrivacy and misuse of dataComputer hackingPlagiarism and software piracyMisuse of a computer resource

    CSCE106

  • Privacy and Misuse of DataAs part of their jobs, programmers may have access to large data containing sensitive/secret information.Programmers should not misuse information, just as doctors and lawyers.Computer theft/fraud is changing financial information, and could lead to fines and imprisonment.

    CSCE106

  • Computer HackingComputer hackers break into secure/classified/confidential data banks by using their own computers.Computer hacking is illegal.Hackers also sometimes attach harmful code, virus, to another program so that it copies itself to a computers disk.Viruses spread from one infected computer to another by copying files or emails.

    CSCE106

  • Plagiarism and Software PiracyPlagiarism, e.g. modifying another students code and submitting it as your own, is fraudulent.Software piracy is the practice of illegally copying software.Copying/Using someone elses programs without permission could lead to lawsuit.Most commercial software packages are protected by copyright laws against software piracy. It is important to read the copyright restrictions on each software package and adhere to them.

    CSCE106

  • Misuse of a Computer ResourceAs computer technology spreads throughout modern society, so do the opportunities for its misuse.Computers, computer programs, data and accounts are like any other property. If they belong to someone else and you are not explicitly given permission to use them, then dont use them.Computer access privileges or user account codes are private property which are usually granted for a specific purpose.

    CSCE106

    Expected time: 40 min.

    This presentation covers: .The history of computer languages is linked to a certain extent to the history of computers.What is the language that the computer understands, as a machine?How could a computer do complex things when it only understands 1s and 0s?Arent machines wired to do specific tasks?Lets go back to early computers.Computer is a device for counting or computing.We could consider the abacus to have been the first computer.The first electronic computer was designed in the late 1930s by Dr John Atanasoff and Clifford Berry, a graduate student, at Iowa State University, to help them perform mathematical computations in nuclear physics.

    The first large-scale, general purpose electronic digital computer, ENIAC (Electronic Numerical Integrator And Calculator), was completed in 1946 at the University of Pennsylvania with funding from the US army.ENIAC, which used more than 18000 vacum tubes, was used to compute ballistics tables, predict weather, and make atomic energy calculations.Its designers were J. Presper Eckert and John Mauchley.

    Dr Von Neumann proposed the use of computer memory to store a program, rather than wires and switches, together with the data.He reasoned that this will make changing the programs far more easier than by connecting wires and setting switches.*Minicomputers, mainframes and supercomputers use time sharing to allow simultaneous access to computing resources.The language that any electric machine could understand is the presence of electricity (1) or its absence (0).Hence the naming of machine language, binary language. A set of 0s and 1s tells the computer what to do.

    Developing software requires writing lists of instructions for a computer to execute.Software developers rarely write instructions in machine language.Machine language is machine (CPU) dependent.Slide contains code for adding two numbers.

    Assembly language is more readable.Assembly language is also machine dependent.Assembly language is represented by mnemonic codes and variables can be given names.An assembler is used to translate assembly language to machine language.

    High-level languages are portable; i.e. machine independent.They combine algebraic expressions and English words.Although programmers find it much easier to write programs in high-level languages, computers do NOT understand these languages as they stand. They must be translated; i.e. compiled, into machine/binary language.The source file is text format.

    The compiler is system software.Syntax: grammar rules.The compiler produces an object file (containing machine language) file.obj, if there are no errors in the source file.

    Although an object file contains machine language instructions, not all of the instructions are complete.The linker is also a system software.Linking with pre-compiled filesObject filesLibrary modulesThe linker produces a complete machine language program that is ready to run.The linker combines object files and resolves cross-references to create an executable machine language program.As long as the executable file is stored on your disk, it does nothing.

    To run the program, the loader must copy its instructions .As the program runs, it takes input data from one or more sources, and sends results/program data to output and/or secondary storage devices.

    Actually you wont be doing any of the above steps separately.

    You will be using an IDE.

    Like other professionals, computer programmers need to follow certain standards of professional conduct.

    We should have an idea about the legal and ethical dimensions of computing so that we will be prepared to deal constructively and responsibly with such issues when they arise.

    We need to understand and appreciate ethical issues related to the use of computers and programming.

    There are four major unprofessional behaviours.It is generally permissible to use modules from libraries that have been developed for reuse by their creators.Software piracy is a violation of the terms of the license agreements.Software Licenses and Piracy By purchasing a software product, a person automatically obtains a license to use that software.Such licenses come with specific restrictions that are designed to protect the manufacturer's rights to the software product. Single-user licenses usually specify the following conditions:1. The software product can be used only on one computer.2. The software product cannot be copied (except for backup) or modified.3. The software cannot be used in the creation of a derivation work.4. The software is provided "as is". The manufacturer is not liable for any damages arising out of the use of the software.Several variations on the single-user license are also widely used. Site licenses are usually purchased by an institution like a college or university.Access privileges or user account codes should not be used for any purpose for which it was not intended.

    Next presentation/lecture will be about: Numbering Systems.