table of Contents
Python 01-- Computer Programming Fundamentals
A, markdown of use
1. Bold
I was bolded
2. italic
I tilted
3. Highlight
I highlighted the == ==
4. The vertical scale
① superscript
2^2^
② subscript
H~2~o
5. Code References
①> style
hello world!
hello world!
hello world!
②``` formula
print('hello world')
③` formula
print('hello world')
6. Insert link
python official website https://www.python.org
[python official website] ( https://www.python.org "Python official website")
7. ordered list
- one
- two
- three
8. unordered list
- one
- two
- three
9. The parting line
10. Form
name | time | late |
---|---|---|
a | 8.25 | no |
b | 8.31 | yes |
11. mathematical formulas
① line built
Embedded mathematical formula \ (\ sum_ {i = 1 } ^ {10} f (i) \, \, \ text {thanks} \)
② block
\[ \sum_{i=1}^{10}f(i)\,\,\text{thanks} \]
Second, the basic computer programming
1. What is the programming language
One medium and computer communication
2. What is programming
Programming means: ape program based on the syntax of a programming language they want their brain will let the computer do, written to a file.
3. Why programming
Instead of labor
Third, the composition of the computer
Composed of five
1. operator
Responsible for arithmetic and logical operations, and a controller with the CPU
2. Controller
Responsible for sending and receiving instructions
3. Memory
It used to store programs that are running, divided
Memory: Advantages: speed
Disadvantages: small capacity, broken disappears
External memory: Advantages: large capacity, permanent storage
Cons: Slow
4. The input device
The output device
Composition of the make
1. The multi-core CPU
A brain equivalent of a CPU, multi-core CPU-- "computers have more than one CPU, processing more than one thing at a time (multi-process)
2.32 and 64
How to store computer images: computer only recognize 0 (low frequency) and 1 (high frequency electric), the picture is essentially a string of 0 and 1
Mouse click - "low-frequency low-frequency low-frequency high-frequency low-frequency electrical -" 00010
Disc - "1 imprinting concave convex 0
32 - "a computer and processing performance 0 32 1
64 - "a computer and processing performance 0 64 1
32 and 64 is essentially the same thing
64 is the installation package (disposable give you 0 and 64 1), the computer is a 32-bit (32 a performance of the receiver 0 and 1)
3. mechanical hard disk works
Robot: read data
Track: storing data
Sector: dividing the track, a plurality of fan (512kb, 512kb computer reads data from the disposable mechanical hard drive) is actually a disc (region)
The average track seek time: 5ms
Average Delay Time: computer-7200r / min for example
\ [7200r / 60s = 120r / s \\ 1s / 120r / s = 0.0083s = 8.3ms \\ (8.3 + 0) /2=4.15ms \\ \ ]
The average time to find data: 5 + 4.15 = 9.15ms
4. Solid State Drive
Based on capacitive storage
Advantages: no mechanical arm, based on the electrical storage
Fourth, the operating system
1. What is the file
Information storage medium, the operating system gives you a virtual concept, the virtual concept can be used to store information to help you slide the mechanical arm
File interface (the operating system, and the file is just an interface): to help you simplify the complex operations of the hardware
Double-click on the interface (the operating system): allows you to quickly open an application
2. The role of the operating system
Give us a an interface that allows complex operations that we no longer care about the hardware, so that simplify complex operations
3. Start the application
Start the application: The application code is hard to read into memory, CPU running the application code, you can use the application to run successfully. Although the operating system boot and application startup has a similar place, but we had to be clear: in order to install the application, only the application of this concept after the installed operating system. Therefore, the application program for hardware control of each step, are dependent on the help of the operating system.
- Double-click QQ-- "allow the operating system to inform CPU (QQ icon is available to your operating system) (QQ find the location in external memory)
- cpu memory to external memory so that the data read QQ, QQ data into the memory
- Start QQ
4. Composition of the computer (the operating system)
- Applications (software): and operating system interaction
- Operating system (software): and hardware interaction
- Hardware: The hardware interact directly
The operating system's startup
The operating system startup: the operating system code into memory (BIOS program) read from the hard disk, CPU to run the operating system code (CMOS memory), after successfully running the operating system takes over operation of the hardware work.
Start the software, first of all start the operating system software to find the location on your hard disk; nature is a software operating system, start the operating system operating system also needs to find the location on your hard drive (it must be looking through the operating system)
Temporary operating system (ROM memory)
Computer factory when he wrote was dead, he will call the operating system area path on the CMOS memory, is only responsible for the operating system's path
Temporary memory (CMOS memory)
Battery power, the operating system stores path (reinstall the operating system boot disk to modify the position of the change is), the storage time
- Boot, boot the temporary operating system
- Find the path of the operating system on a temporary operating system CMOS memory area
- Start the operating system, the operating system is shut down temporarily