14.
:
1. .
2. .
3. .
4. .
5. .
6. .
7. .
8. .
9. .
10. .
11. .
12. .
13. .
14. .
15.
(file) . , .
. . , 50 , file ( ). . file : , (, ) , , "" . " X files" ( " ").
IBM IBM 360 1960- . (data set) , , .
, , . () . , () ( ).
. , . . UNIX: . , , , (read, write) . , IBM 360, "". , , , .
( , ).
|
|
(records) , . :
, ;
;
.
, :
Microsoft Office ( , , , ..);
, , portable executable (PE) - .NET; class- Java; , ..
.
.
, . , , , , .., .
:
(Name) , .
(Type) . , . , "" , : 0 , 2 , 3 .. , MS DOS, Windows, UNIX: , , book.txt (.txt), .
(Location) .
(Size) .
(Protection) , , .
. , . () , (, make) , .
UNIX touch f, f . Touch . , .
. () (owner). .
( - directories),, , Windows, (folders) , . .
, .
|
|
(Create). ; () .
(Write). , (records) , , -.
(Read). .
() (Seek). , , ( ) ( ).
(Delete). , (UNIX) (MS DOS).
(Truncate).
(Open) () .
(Close) ; ; , .
(read, write), , . ; , - , , , .
1 .
1. | ||
( ) | exe, com, bin | |
obj, | , | |
, , Java, pas, asm, | (, .) | |
bat, sh | ||
txt, doc | , | |
wp, tex, rtf, doc | - | |
lib, a, so, dll, mpeg, mov, rm | ||
arc, zip, tar | ASCII | |
arc, zip, tar | , , | |
mpeg, mov, rm | , - |
. , , , -, .txt () , , .c , .p . pas . - ( Windows .obj, UNIX - .o), : Windows - .lib, UNIX - .a; Windows - .dll, UNIX .so. , Windows - .exe, UNIX , : a.out (assembler output). :. doc - Microsoft Word, .pdf Adobe Acrobat .
. , () . , . , , , . , , () .
|
|
, (, , ), .
-, : , .
:
read next
write next
reset
rewrite .
:
read n
write n
position to n n
read next
write next
rewrite n, n - ().
. 1.
. 1. .
. 2.
2. | |
reset | cp =0; |
read next | read cp; cp = cp +1; |
write next | write cp; cp = cp +1; |
, , cp, cp .
, () . .2 , . , , Smith.
. 2. .
(directory, folder) - , . , , . , . (paths) , ( ) . , Windows c:\doc\plan.txt , C:, doc (), plan.txt. , .
(back-up) , (), flash- , , - (CD, DVD). ( ) .
""
, , "". , .
|
|
"" , , . "" Windows Solaris: . .
"" . , 100 (!).
"" , , .. (). , , , . , ( "" , c ) (). . , . : () (), , . , . .
"" , , , . "", UNIX , .
. 3.
. 3. .
. (partitions) , ( ). , . Partition Magic. . , , .
, , . , , , Windows A FAT32, B NTFS. C Linux, Ext2Fs.
, , . , API. . GUI .
() . () , cd (change directory),, C:, :
cd doc
doc. (.).
. , (path), , , C:\doc\plan.txt. , . , Windows :
type plan. txt
plan.txt (C:\doc) .
. , , , Windows notepad, wordpad, Microsoft Word. , - . , Java program.java, :
|
|
javac program.java
Java - class-, - Java - program.class.
, , - , Microsoft Word . .
. . mkdir, :
mkdir tmp.
- del ( Windows) rm ( UNIX). , . , . . Windows, , , ( ), , , FAT . UNIX, , , , UNIX , .
. dir ( Windows) ls ( UNIX) . , :
ls doc > doc_list.txt
. , . UNIX mv, :
mv old_file.txt new_file.txt
. . , , , , , , , make- , . UNIX ln, :
cd /my_dir
ln s /doc doc
my_dir /doc, doc. , /doc / my_dir/doc . UNIX .
. , , , . , UNIX :
find. name plan. txt print
plan. txt .
"", "", , () . , , , .