Content deleted Content added
Removed atrocious unreliable source. The author is a perpetuator of hoaxes about his own accomplishments. See his linkedin for more on how he created the IMSAI 8080 and founded ComputerLand and created WordStar and created the standard test programs used by all the major chip manufacturers and built the first Old Spaghetti Factory alongside other equally fanciful claims. https://www.linkedin.com/in/bill-pentz-29584711/details/experience/ Tag: Reverted |
m Reverted edit by 154.208.37.23 (talk) to last version by Annh07 |
||
(27 intermediate revisions by 18 users not shown) | |||
Line 3:
[[File:JavaScript_code.png|thumb|[[Source code]] for a computer program written in the [[JavaScript]] language. It demonstrates the ''appendChild'' method. The method adds a new child node to an existing parent node. It is commonly used to dynamically modify the structure of an HTML document.]]
{{Program execution}}
A '''computer program''' is a [[sequence]] or set{{efn|The [[Prolog]] language allows for a database of facts and rules to be entered in any order. However, a question about a database must be at the very end.}} of instructions in a [[programming language]] for a [[computer]] to [[Execution (computing)|execute]]. It is one component of [[software]], which also includes [[software documentation|documentation]] and other intangible components.<ref name="ISO 2020">{{cite web
| title=ISO/IEC 2382:2015
Line 15 ⟶ 16:
}}</ref>
A ''computer program'' in its [[human-readable]] form is called [[source code]]. Source code needs another computer program to
| last = Wilson
| first = Leslie B.
Line 45 ⟶ 46:
}}</ref>
If the source code is requested for execution, then the operating system loads the corresponding interpreter into memory and starts a process. The interpreter then loads the source code into memory to translate and execute each [[Statement (computer science)|statement]]. Running the source code is slower than running an
| last = Wilson
| first = Leslie B.
Line 57 ⟶ 58:
==Example computer program==
The [["Hello, World!" program]] is used to illustrate a language's basic
| last = Wilson
| first = Leslie B.
Line 204 ⟶ 205:
===ENIAC===
[[File:ENIAC-changing_a_tube.jpg|thumb|right|Glenn A. Beck changing a tube in ENIAC]]
The [[Electronic Numerical Integrator And Computer]] (ENIAC) was built between July 1943 and Fall 1945. It was a
| last = McCartney
| first = Scott
Line 365 ⟶ 366:
}}</ref> The MOS transistor is the primary component in ''integrated circuit chips''.<ref name="digital_age"/>
Originally, [[integrated circuit]] chips had their function set during manufacturing. During the 1960s, controlling the electrical flow migrated to programming a [[Diode matrix|matrix]] of [[read-only memory]] (ROM). The matrix resembled a two-dimensional array of fuses. The process to embed instructions onto the matrix was to burn out the unneeded connections. There were so many connections, [[firmware]] programmers wrote a ''computer program'' on another chip to oversee the burning. The technology became known as [[Programmable ROM]]. In 1971, Intel
| url=https://spectrum.ieee.org/chip-hall-of-fame-intel-4004-microprocessor
| title=Chip Hall of Fame: Intel 4004 Microprocessor
Line 387 ⟶ 388:
===x86 series===
[[File:IBM_PC-IMG_7271_(transparent).png|thumb|right|The original [[IBM Personal Computer]] (1981) used an Intel 8088 microprocessor.]]
In 1978, the modern
| url=https://books.google.com/books?id=VDAEAAAAMBAJ&pg=PA22
| title=Bill Gates, Microsoft and the IBM Personal Computer
Line 409 ⟶ 410:
==Programming paradigms and languages==
| last = Stroustrup
| first = Bjarne
Line 485 ⟶ 486:
| isbn = 978-0-13-854662-5
| url = https://archive.org/details/structuredcomput00tane/page/17
}}</ref> Programming the EDSAC was in the first [[Programming language generations|generation of programming language]].<ref>{{Citation |last1=Wilkes |first1=M. V. |title=The EDSAC |date=1982 |work=The Origins of Digital Computers: Selected Papers |pages=417–421 |editor-last=Randell |editor-first=Brian |url=https://link.springer.com/chapter/10.1007/978-3-642-61812-3_34 |access-date=2025-04-25 |place=Berlin, Heidelberg |publisher=Springer |language=en |doi=10.1007/978-3-642-61812-3_34 |isbn=978-3-642-61812-3 |last2=Renwick |first2=W.|url-access=subscription }}</ref>
* The [[First-generation programming language|first generation of programming language]] is [[machine language]].<ref name="pis-ch4-p160">{{cite book
Line 495 ⟶ 496:
| page = 160
| isbn = 0-619-06489-7
}}</ref> ''Machine language'' requires the programmer to enter instructions using ''instruction numbers'' called [[machine code]]. For example, the ADD operation on the [[PDP-11 architecture|PDP-11]] has instruction number 24576.{{efn|Whereas this is a decimal number, PDP-11 code is always expressed as [[octal]].}}<ref name="sco-ch7-p399">{{cite book
| last = Tanenbaum
| first = Andrew S.
Line 506 ⟶ 507:
}}</ref>
* The [[Second-generation programming language|second generation of programming language]] is [[assembly language]].<ref name="pis-ch4-p160"/> ''Assembly language'' allows the programmer to use [[Assembly language#Mnemonics|mnemonic]] [[Instruction_set_architecture#Instructions|instructions]] instead of remembering instruction numbers. An [[Assembler (computing)|assembler]] translates each assembly language mnemonic into its machine language number. For example, on the PDP-11, the operation 24576 can be referenced as ADD R0,R0 in the source code.<ref name="sco-ch7-p399"/> The four basic arithmetic operations have assembly instructions like ADD, SUB, MUL, and DIV.<ref name="sco-ch7-p399"/> Computers also have instructions like DW (Define [[Word (computer architecture)|Word]]) to reserve [[Random-access memory|memory]] cells. Then the MOV instruction can copy [[integer]]s between [[Processor register|registers]] and memory.
:* The basic structure of an assembly language statement is a label, [[Operation (mathematics)|operation]], [[operand]], and comment.<ref name="sco-ch7-p400">{{cite book
Line 640 ⟶ 641:
| page = 19
| isbn = 0-201-71012-9
}}</ref> Emerging from a committee of European and American programming language experts, it used standard [[mathematical notation]] and had a readable, structured design. Algol was first to define its
* [[Block (programming)|block structure]], where variables were local to their block.
* arrays with variable bounds.
Line 662 ⟶ 663:
====C====
[[C programming language]] (1973) got its name because the language [[BCPL]] was replaced with [[B (programming language)|B]], and [[AT&T Bell Labs]] called the next version "C". Its purpose was to write the [[UNIX]] [[operating system]].<ref name="cpl_3rd-ch2-37"/> C is a relatively small language, making it easy to write compilers. Its growth mirrored the hardware growth in the 1980s.<ref name="cpl_3rd-ch2-37"/> Its growth also was because it has the facilities of [[assembly language]], but it uses a [[High-level programming language|high-level syntax]]. It added advanced features like:
* [[inline assembler]].
* arithmetic on pointers.
Line 1,258 ⟶ 1,259:
</syntaxhighlight>
Here is a comprehensive example:<ref name="Logical English">Kowalski, R., Dávila, J., Sartor, G. and Calejo, M., 2023. Logical English for law and education. In Prolog: The Next 50 Years (pp.
1) All dragons billow fire, or equivalently, a thing billows fire if the thing is a dragon:
Line 1,917 ⟶ 1,918:
The levels of coupling from worst to best are:<ref name="se-ch8-226"/>
* ''Content Coupling'': A module has content coupling if it modifies a [[local variable]] of another function. COBOL used to do this with the ''alter'' verb.
* ''Common Coupling'': A module has common coupling if it modifies a global variable.
* ''Control Coupling'': A module has control coupling if another module can modify its [[control flow]]. For example, <code>perform_arithmetic( perform_addition, a, b )</code>. Instead, control should be on the makeup of the returned object.
Line 2,066 ⟶ 2,067:
|year=2010
|isbn=978-1-59327-220-3
|page=22}}</ref> which is also known as a [[context switch]]. The kernel creates a [[process control block]] when a ''computer program'' is [[Loader (computing)|selected for execution]]. However, an executing program gets exclusive access to the [[central processing unit]] only for a [[
[[File:Virtual memory.svg|thumb|250px|Physical memory is scattered around RAM and the hard disk. Virtual memory is one continuous block.]]
* The kernel program should perform [[memory management]].
Line 2,259 ⟶ 2,260:
| year = 2013
| page = 249
| isbn = 978-0-13-291652-3
}}</ref>
|