Computer program

Computer programs (also software programs, or just programs) are instructions for a computer.[1] A computer requires programs to function, typically executing the program's instructions in a central processor.[2] The program has an executable form that th
computer mouse 135 jpg 18 Jul 2005 13 37 5 0K computer mouse small  > 20 Sep 2002 13 43 3 0K computer program con  > 06 Nov 2003 13 42 22K comstock small jpg 17 Dec 2002 17 07 3 7K
is a voice output facility which enables students to play back what they have written  But it is only a trial version  the computer must be rebooted after 40 minutes  From JAWS to Dolphins JAWS is limited because it deals with speech only  Martin Kieti sa
SBFV greatly appreciates the support of the Hugh D T  Williamson Foundation and the Holmesglen Institute of TAFE for supporting the development of this project  Further Information  If you would like more information about this program  please contact  El
SBFV greatly appreciates the support of the Hugh D T  Williamson Foundation and the Holmesglen Institute of TAFE for supporting the development of this project  Further Information  If you would like more information about this program  please contact
Everyone knows what a shoddy year it s been for movies  Cinema goers have been underwhelmed left  right and centre by pap like The Island  Stealth and Bewitched   But it looks like a
Capt   Dr   Allen Holder  left  discusses graphical interface elements for the new EM3 patient tracking system at Wilford Hall Medical Center with software engineer Ed
There are no restrictions on the use of the software  Neither Charles or the web site owner accept any responsibility for any claim or claims arising from the use of the software  Charlie had developed a number of programs to study many different designs
Source: http://en.wikipedia.org/wiki/Computer_program

From Wikipedia, the free encyclopedia

Jump to: navigation, search

Computer programs (also software programs, or just programs) are instructions for a computer.[1] A computer requires programs to function, typically executing the program's instructions in a central processor.[2] The program has an executable form that the computer can use directly to execute the instructions. The same program in its human-readable source code form, from which executable programs are derived (e.g., compiled), enables a programmer to study and develop its algorithms.

Computer source code is often written by professional computer programmers. Source code is written in a programming language that usually follows one of two main paradigms: imperative or declarative programming. Source code may be converted into an executable file (sometimes called an executable program or a binary) by a compiler. Alternatively, computer programs may be executed by a central processing unit with the aid of an interpreter, or may be embedded directly into hardware.

Computer programs may be categorized along functional lines: system software and application software. And many computer programs may run simultaneously on a single computer, a process known as multitasking.

Contents

  • 1 Programming
    • 1.1 Paradigms
    • 1.2 Compilation or interpretation
    • 1.3 Self-modifying programs
  • 2 Execution and storage
    • 2.1 Embedded programs
    • 2.2 Manual programming
    • 2.3 Automatic program generation
    • 2.4 Simultaneous execution
  • 3 Functional categories
  • 4 See also
  • 5 References
  • 6 Further reading
  • 7 External links

Programming

#include <stdio.h>
int main(void)
{

puts("Hello world!");
return 0;

}

Source code of a program written in the C programming language

Computer programming is the iterative process of writing or editing source code. Editing source code involves testing, analyzing, and refining, and sometimes coordinating with other programmers on a jointly developed program. A person who practices this skill is referred to as a computer programmer or software developer. The sometimes lengthy process of computer programming is usually referred to as software development. The term software engineering is becoming popular as the process is seen as an engineering discipline.

Paradigms

Computer programs can be categorized by the programming language paradigm used to produce them. Two of the main paradigms are imperative and declarative.

Programs written using an imperative language specify an algorithm using declarations, expressions, and statements.[3] A declaration couples a variable name to a datatype. For example: var x: integer; . An expression yields a value. For example: 2 + 2 yields 4. Finally, a statement might assign an expression to a variable or use the value of a variable to alter the program's control flow. For example: x := 2 + 2; if x = 4 then do_something(); One criticism of imperative languages is the side-effect of an assignment statement on a class of variables called non-local variables.[4]

Programs written using a declarative language specify the properties that have to be met by the output and do not specify any implementation details. Two broad categories of declarative languages are functional languages and logical languages. The principle behind functional languages (like Haskell) is to not allow side-effects, which makes it easier to reason about programs like mathematical functions.[4] The principle behind logical languages (like Prolog) is to define the problem to be solved — the goal — and leave the detailed solution to the Prolog system itself.[5] The goal is defined by providing a list of subgoals. Then each subgoal is defined by further providing a list of its subgoals, etc. If a path of subgoals fails to find a solution, then that subgoal is backtracked and another path is systematically attempted.

The form in which a program is created may be textual or visual. In a visual language program, elements are graphically manipulated rather than textually specified.

Compilation or interpretation

A computer program in the form of a human-readable, computer programming language is called source code. Source code may be converted into an executable image by a compiler or executed immediately with the aid of an interpreter.

Either compiled or interpreted programs might be executed in a batch process without human interaction, but interpreted programs allow a user to type commands in an interactive session. In this case the programs are the separate commands, whose execution is chained together. When a language is used to give commands to a software application (such as a shell) it is called a scripting language.

Compiled computer programs are commonly referred to as executables, binary images, or simply as binaries — a reference to the binary file format used to store the executable code. Compilers are used to translate source code from a programming language into either object code or machine code. Object code needs further processing to become machine code, and machine code is the Central Processing Unit's native code, ready for execution.

Interpreted computer programs -in a batch or interactive session- are either decoded and then immediately executed or are decoded into some efficient intermediate representation for future execution. BASIC, Perl, and Python are examples of immediately executed computer programs. Alternatively, Java computer programs are compiled ahead of time and stored as a machine independent code called bytecode. Bytecode is then executed upon request by an interpreter called a virtual machine.

The main disadvantage of interpreters is computer programs run slower than if compiled. Interpreting code is slower than running the compiled version because the interpreter must decode each statement each time it is loaded and then perform the desired action. On the other hand, software development may be quicker using an interpreter because testing is immediate when the compilation step is omitted. Another disadvantage of interpreters is the interpreter must be present on the computer at the time the computer program is executed. By contrast, compiled computer programs need not have the compiler present at the time of execution.

No properties of a programming language require it to be exclusively compiled or exclusively interpreted. The categorization usually reflects the most popular method of language execution. For example, BASIC is thought of as an interpreted language and C a compiled language, despite the existence of BASIC compilers and C interpreters. Some systems use Just-in-time compilation (JIT) whereby sections of the source are compiled 'on the fly' and stored for subsequent executions.

Self-modifying programs

A computer program in execution is normally treated as being different from the data the program operates on. However, in some cases this distinction is blurred when a computer program modifies itself. The modified computer program is subsequently executed as part of the same program. Self-modifying code is possible for programs written in Machine code, assembly language, Lisp, COBOL, PL/1 and Prolog, among others.

Execution and storage

Typically, computer programs are stored in non-volatile memory until requested either directly or indirectly to be executed by the computer user. Upon such a request, the program is loaded into random access memory, by a computer program called an operating system, where it can be accessed directly by the central processor. The central processor then executes ("runs") the program, instruction by instruction, until termination. A program in execution is called a process.[6] Termination is either by normal self-termination or by error — software or hardware error.

Embedded programs

The microcontroller on the right of this USB flash drive is controlled with embedded firmware.

Some computer programs are embedded into hardware. A stored-program computer requires an initial computer program stored in its read-only memory to boot. The boot process is to identify and initialize all aspects of the system, from CPU registers to device controllers to memory contents.[7] Following the initialization process, this initial computer program loads the operating system and sets the program counter to begin normal operations. Independent of the host computer, a hardware device might have embedded firmware to control its operation. Firmware is used when the computer program is rarely or never expected to change, or when the program must not be lost when the power is off.[8]

Manual programming

Switches for manual input on a Data General Nova 3

Computer programs historically were manually input to the central processor via switches. An instruction was represented by a configuration of on/off settings. After setting the configuration, an execute button was pressed. This process was then repeated. Computer programs also historically were manually input via paper tape or punched cards. After the medium was loaded, the starting address was set via switches and the execute button pressed.[9]

Automatic program generation

Generative programming is a style of computer programming that creates source code through generic classes, prototypes, templates, aspects, and code generators to improve programmer productivity. Source code is generated with programming tools such as a template processor or an Integrated Development Environment. The simplest form of source code generator is a macro processor, such as the C preprocessor, which replaces patterns in source code according to relatively simple rules.

Software engines output source code or markup code that simultaneously become the input to another computer process. The analogy is that of one process driving another process, with the computer code being burned as fuel. Application servers are software engines that deliver applications to client computers. For example, a Wiki is an application server that allows users to build dynamic content assembled from articles. Wikis generate HTML, CSS, Java, and Javascript which are then interpreted by a web browser.

Simultaneous execution

Many operating systems support multitasking which enables many computer programs to appear to be running simultaneously on a single computer. Operating systems may run multiple programs through process scheduling — a software mechanism to switch the CPU among processes frequently so that users can interact with each program while it is running.[10] Within hardware, modern day multiprocessor computers or computers with multicore processors may run multiple programs.[11]

Functional categories

Computer programs may be categorized along functional lines. These functional categories are system software and application software. System software includes the operating system which couples the computer's hardware with the application software.[12] The purpose of the operating system is to provide an environment in which application software executes in a convenient and efficient manner.[12] In addition to the operating system, system software includes utility programs that help manage and tune the computer. If a computer program is not system software then it is application software. Application software includes middleware, which couples the system software with the user interface. Application software also includes utility programs that help users solve application problems, like the need for sorting.

See also

References

  1. ^ Stair, Ralph M., et al. (2003). Principles of Information Systems, Sixth Edition. Thomson Learning, Inc.. pp. 132. ISBN 0-619-06489-7. 
  2. ^ Silberschatz, Abraham (1994). Operating System Concepts, Fourth Edition. Addison-Wesley. pp. 58. ISBN 0-201-50480-4. 
  3. ^ Wilson, Leslie B. (1993). Comparative Programming Languages, Second Edition. Addison-Wesley. pp. 75. ISBN 0-201-56885-3. 
  4. ^ a b Wilson, Leslie B. (1993). Comparative Programming Languages, Second Edition. Addison-Wesley. pp. 213. ISBN 0-201-56885-3. 
  5. ^ Wilson, Leslie B. (1993). Comparative Programming Languages, Second Edition. Addison-Wesley. pp. 244. ISBN 0-201-56885-3. 
  6. ^ Silberschatz, Abraham (1994). Operating System Concepts, Fourth Edition. Addison-Wesley. pp. 97. ISBN 0-201-50480-4. 
  7. ^ Silberschatz, Abraham (1994). Operating System Concepts, Fourth Edition. Addison-Wesley. pp. 30. ISBN 0-201-50480-4. 
  8. ^ Tanenbaum, Andrew S. (1990). Structured Computer Organization, Third Edition. Prentice Hall. pp. 11. ISBN 0-13-854662-2. 
  9. ^ Silberschatz, Abraham (1994). Operating System Concepts, Fourth Edition. Addison-Wesley. pp. 6. ISBN 0-201-50480-4. 
  10. ^ Silberschatz, Abraham (1994). Operating System Concepts, Fourth Edition. Addison-Wesley. pp. 100. ISBN 0-201-50480-4. 
  11. ^ Akhter, Shameem (2006). Multi-Core Programming. Richard Bowles (Intel Press). pp. 11–13. ISBN 0-9764832-4-6. 
  12. ^ a b Silberschatz, Abraham (1994). Operating System Concepts, Fourth Edition. Addison-Wesley. pp. 1. ISBN 0-201-50480-4. 

Further reading

  • Knuth, Donald E. (1997). The Art of Computer Programming, Volume 1, 3rd Edition. Boston: Addison-Wesley. ISBN 0-201-89683-4. 
  • Knuth, Donald E. (1997). The Art of Computer Programming, Volume 2, 3rd Edition. Boston: Addison-Wesley. ISBN 0-201-89684-2. 
  • Knuth, Donald E. (1997). The Art of Computer Programming, Volume 3, 3rd Edition. Boston: Addison-Wesley. ISBN 0-201-89685-0. 

External links

Retrieved from "http://en.wikipedia.org/wiki/Computer_program"

Adobe Acrobat Document Download Adobe Acrobat (pdf) files


[pdf] Computer program
Program Operations Guidelines, CDC is providing STD ... eight major CSPS sections: Leadership and Program ... 18 members from program operations, research, sur ...
[pdf] Computer program
(CSCI) or in computer information systems (CIS) ... CSCI 325 Org of Program Lang (3) CSC 411 Computer Organization (4) Free Elective (4) ...
[pdf] Computer program
... An undergraduate degree in Computer Science (CS) is a limited access program. ... Students must maintain a 2.0 GPA to remain in the program. ...
[pdf] Computer program
The Career Connections program in computer programming is intended as a guide for ... In parallel to the development of the software (or computer program) ...
[pdf] Computer program
Computer Graphics Education Consultant ... cannot be translated to the computer this tool does give students the ... computer technology to our media choices in ...
[pdf] Computer program
royalty free without further permission by computer-based and. other information-service systems. ... setting is a re-execution of the program in which all ...
[pdf] Computer program
identify the basic internal components of the computer ... maintain backup copies of program files on different media ... that conform to a program. design ...
[pdf] Computer program
able on modern computer systems. In this paper, we identify another type of program invari ... International Symposium on Computer Architecture (ISCA'04), June, 2004. ...
[pdf] Computer program
... workshop focused on the topic of "The Disappearing Computer" (DC) ... Consequently, one core problem for the disappearing computers is how to program them. ...
[pdf] Computer program
How do I pay my USD$100 program offering fee? Benefits of working with a Network Partner . part of the BizSpark program benefits and Startup's participation ...

Show more pdf files...
Powerpoint Documents Download Powerpoint slide (ppt) files
[ppt] Computer program
Program represented by source tree (source graph) ... The order of reductions is implicit -> not a general program transformation system ...
[ppt] Computer program
Severe - error must be corrected to complete program compilation ... Run program. Compare computer-produced results to expected results ...
[ppt] Computer program
COMPUTER VIRUSES—SEGMENTS OF CODE THAT CAN PERFORM MALICIOUS ACTS AND INSERT ... THE ATTACKED PROGRAM MAY WORK PROPERLY, HOWEVER, AT SOME POINT A MALICIOUS ACT ...
[ppt] Computer program
Set of instructions to be executed by program ... type in and run a COBOL program on your computer system, you need to know how to: ...
[ppt] Computer program
Ending a program, retrying , and reporting errors. Accounting ... program in machine code. error indicated ... batch O.S. is simply a computer program. ...
[ppt] Computer program
As program logic we use Dijkstra's weakest preconditions ... Our program rules prevent data races by ensuring that access sets of different ...
[ppt] Computer program
DoE NGI Program PI Meeting, October 1999. Particle Physics Data Grid Richard P. Mount, SLAC ... Universities, DoE Accelerator Labs, DoE Computer Science ...
[ppt] Computer program
... program that acts as an intermediary between a user of a computer and the computer ... "The one program running at all times on the computer" is the kernel. ...
[ppt] Computer program
When the computer runs your program, it will do exactly what you told it to do. ... In the old days, to write a computer program, you had to learn to convert every ...
[ppt] Computer program
Program evaluation is the use of social research methods to systematically ... The values and concepts inherent in the program rationale and design. ...

Show more powerpoint files...
Download Powerpoint slide (ppt) files


[msword] Computer program
This program will be launched by a mini-OS and act as an interactive shell ... 1. The Advanced Computer Structure Laboratory currently uses the XESS XSA-50 ...
[msword] Computer program
A program in a third-generation language is machine independent in the sense ... and less in terms of computer gibberish than do the earlier-generation languages. ...
[msword] Computer program
Computer-based imaging is rapidly becoming an integral factor in academia and industry. ... an annual animation festival, and an annual student grant program. ...
[msword] Computer program
EMPLOYEE COMPUTER USE POLICY ... allow others to use their computer accounts. ... Possession of a program designed to gain unauthorized access will be deemed to ...
[msword] Computer program
... program that is undergoing a joint visit by both CAC under the computer science ... evaluate a computer-based system, process, component, or program to meet ...
[msword] Computer program
Getting the IP Addresses and Subnet Masks of a Remote Computer ... Connecting to a remote computer and retrieving basic settings. ...
[msword] Computer program
Faculty of Computer Studies. 2- برنامج تقنية المعلومات المحدث ( الخطة الدراسية ) ... Faculty of Computer Studies. 4- الحاسب الآلي بالإعمال Computing with ...
[msword] Computer program
The sequential program would loop through the array summing all of the values to ... and report the name of the computer running that process back to the user. ...
[msword] Computer program
Any number of these program types can be selected. ... At the end of a program's detail page are two choices to search for a realtor or ...
[msword] Computer program
... a computer, you are really talking to a program which is talking to the ... When a program running on the computer requests a file, the hard disk retrieves ...

Show more ms word files...
Top