home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
view JSON data
|
view as text
This file was processed as: LaTeX Document
(document/latex).
You can browse this item here: ref1.tex
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| LaTeX Document (document/latex)
| magic
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| LaTeX document text
| default
| |
99%
| file
| LaTeX document, ASCII text, with CR line terminators
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/281 LaTeX (Subdocument)
| default
| |
100%
| detectItEasy
| Format: plain text[CR]
| default (weak)
|
|
id metadata |
---|
key | value |
---|
macFileType | [TEXT] |
macFileCreator | [R*ch] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 5c 63 68 61 70 74 65 72 | 7b 49 6e 74 72 6f 64 75 |\chapter|{Introdu|
|00000010| 63 74 69 6f 6e 7d 0d 0d | 54 68 69 73 20 72 65 66 |ction}..|This ref|
|00000020| 65 72 65 6e 63 65 20 6d | 61 6e 75 61 6c 20 64 65 |erence m|anual de|
|00000030| 73 63 72 69 62 65 73 20 | 74 68 65 20 50 79 74 68 |scribes |the Pyth|
|00000040| 6f 6e 20 70 72 6f 67 72 | 61 6d 6d 69 6e 67 20 6c |on progr|amming l|
|00000050| 61 6e 67 75 61 67 65 2e | 0d 49 74 20 69 73 20 6e |anguage.|.It is n|
|00000060| 6f 74 20 69 6e 74 65 6e | 64 65 64 20 61 73 20 61 |ot inten|ded as a|
|00000070| 20 74 75 74 6f 72 69 61 | 6c 2e 0d 0d 57 68 69 6c | tutoria|l...Whil|
|00000080| 65 20 49 20 61 6d 20 74 | 72 79 69 6e 67 20 74 6f |e I am t|rying to|
|00000090| 20 62 65 20 61 73 20 70 | 72 65 63 69 73 65 20 61 | be as p|recise a|
|000000a0| 73 20 70 6f 73 73 69 62 | 6c 65 2c 20 49 20 63 68 |s possib|le, I ch|
|000000b0| 6f 73 65 20 74 6f 20 75 | 73 65 20 45 6e 67 6c 69 |ose to u|se Engli|
|000000c0| 73 68 0d 72 61 74 68 65 | 72 20 74 68 61 6e 20 66 |sh.rathe|r than f|
|000000d0| 6f 72 6d 61 6c 20 73 70 | 65 63 69 66 69 63 61 74 |ormal sp|ecificat|
|000000e0| 69 6f 6e 73 20 66 6f 72 | 20 65 76 65 72 79 74 68 |ions for| everyth|
|000000f0| 69 6e 67 20 65 78 63 65 | 70 74 20 73 79 6e 74 61 |ing exce|pt synta|
|00000100| 78 20 61 6e 64 0d 6c 65 | 78 69 63 61 6c 20 61 6e |x and.le|xical an|
|00000110| 61 6c 79 73 69 73 2e 20 | 20 54 68 69 73 20 73 68 |alysis. | This sh|
|00000120| 6f 75 6c 64 20 6d 61 6b | 65 20 74 68 65 20 64 6f |ould mak|e the do|
|00000130| 63 75 6d 65 6e 74 20 6d | 6f 72 65 20 75 6e 64 65 |cument m|ore unde|
|00000140| 72 73 74 61 6e 64 61 62 | 6c 65 0d 74 6f 20 74 68 |rstandab|le.to th|
|00000150| 65 20 61 76 65 72 61 67 | 65 20 72 65 61 64 65 72 |e averag|e reader|
|00000160| 2c 20 62 75 74 20 77 69 | 6c 6c 20 6c 65 61 76 65 |, but wi|ll leave|
|00000170| 20 72 6f 6f 6d 20 66 6f | 72 20 61 6d 62 69 67 75 | room fo|r ambigu|
|00000180| 69 74 69 65 73 2e 0d 43 | 6f 6e 73 65 71 75 65 6e |ities..C|onsequen|
|00000190| 74 6c 79 2c 20 69 66 20 | 79 6f 75 20 77 65 72 65 |tly, if |you were|
|000001a0| 20 63 6f 6d 69 6e 67 20 | 66 72 6f 6d 20 4d 61 72 | coming |from Mar|
|000001b0| 73 20 61 6e 64 20 74 72 | 69 65 64 20 74 6f 20 72 |s and tr|ied to r|
|000001c0| 65 2d 69 6d 70 6c 65 6d | 65 6e 74 0d 50 79 74 68 |e-implem|ent.Pyth|
|000001d0| 6f 6e 20 66 72 6f 6d 20 | 74 68 69 73 20 64 6f 63 |on from |this doc|
|000001e0| 75 6d 65 6e 74 20 61 6c | 6f 6e 65 2c 20 79 6f 75 |ument al|one, you|
|000001f0| 20 6d 69 67 68 74 20 68 | 61 76 65 20 74 6f 20 67 | might h|ave to g|
|00000200| 75 65 73 73 20 74 68 69 | 6e 67 73 20 61 6e 64 20 |uess thi|ngs and |
|00000210| 69 6e 0d 66 61 63 74 20 | 79 6f 75 20 77 6f 75 6c |in.fact |you woul|
|00000220| 64 20 70 72 6f 62 61 62 | 6c 79 20 65 6e 64 20 75 |d probab|ly end u|
|00000230| 70 20 69 6d 70 6c 65 6d | 65 6e 74 69 6e 67 20 71 |p implem|enting q|
|00000240| 75 69 74 65 20 61 20 64 | 69 66 66 65 72 65 6e 74 |uite a d|ifferent|
|00000250| 20 6c 61 6e 67 75 61 67 | 65 2e 0d 4f 6e 20 74 68 | languag|e..On th|
|00000260| 65 20 6f 74 68 65 72 20 | 68 61 6e 64 2c 20 69 66 |e other |hand, if|
|00000270| 20 79 6f 75 20 61 72 65 | 20 75 73 69 6e 67 0d 50 | you are| using.P|
|00000280| 79 74 68 6f 6e 20 61 6e | 64 20 77 6f 6e 64 65 72 |ython an|d wonder|
|00000290| 20 77 68 61 74 20 74 68 | 65 20 70 72 65 63 69 73 | what th|e precis|
|000002a0| 65 20 72 75 6c 65 73 20 | 61 62 6f 75 74 20 61 20 |e rules |about a |
|000002b0| 70 61 72 74 69 63 75 6c | 61 72 20 61 72 65 61 20 |particul|ar area |
|000002c0| 6f 66 0d 74 68 65 20 6c | 61 6e 67 75 61 67 65 20 |of.the l|anguage |
|000002d0| 61 72 65 2c 20 79 6f 75 | 20 73 68 6f 75 6c 64 20 |are, you| should |
|000002e0| 64 65 66 69 6e 69 74 65 | 6c 79 20 62 65 20 61 62 |definite|ly be ab|
|000002f0| 6c 65 20 74 6f 20 66 69 | 6e 64 20 74 68 65 6d 20 |le to fi|nd them |
|00000300| 68 65 72 65 2e 0d 0d 49 | 74 20 69 73 20 64 61 6e |here...I|t is dan|
|00000310| 67 65 72 6f 75 73 20 74 | 6f 20 61 64 64 20 74 6f |gerous t|o add to|
|00000320| 6f 20 6d 61 6e 79 20 69 | 6d 70 6c 65 6d 65 6e 74 |o many i|mplement|
|00000330| 61 74 69 6f 6e 20 64 65 | 74 61 69 6c 73 20 74 6f |ation de|tails to|
|00000340| 20 61 20 6c 61 6e 67 75 | 61 67 65 0d 72 65 66 65 | a langu|age.refe|
|00000350| 72 65 6e 63 65 20 64 6f | 63 75 6d 65 6e 74 20 2d |rence do|cument -|
|00000360| 2d 2d 20 74 68 65 20 69 | 6d 70 6c 65 6d 65 6e 74 |-- the i|mplement|
|00000370| 61 74 69 6f 6e 20 6d 61 | 79 20 63 68 61 6e 67 65 |ation ma|y change|
|00000380| 2c 20 61 6e 64 20 6f 74 | 68 65 72 0d 69 6d 70 6c |, and ot|her.impl|
|00000390| 65 6d 65 6e 74 61 74 69 | 6f 6e 73 20 6f 66 20 74 |ementati|ons of t|
|000003a0| 68 65 20 73 61 6d 65 20 | 6c 61 6e 67 75 61 67 65 |he same |language|
|000003b0| 20 6d 61 79 20 77 6f 72 | 6b 20 64 69 66 66 65 72 | may wor|k differ|
|000003c0| 65 6e 74 6c 79 2e 20 20 | 4f 6e 20 74 68 65 0d 6f |ently. |On the.o|
|000003d0| 74 68 65 72 20 68 61 6e | 64 2c 20 74 68 65 72 65 |ther han|d, there|
|000003e0| 20 69 73 20 63 75 72 72 | 65 6e 74 6c 79 20 6f 6e | is curr|ently on|
|000003f0| 6c 79 20 6f 6e 65 20 50 | 79 74 68 6f 6e 20 69 6d |ly one P|ython im|
|00000400| 70 6c 65 6d 65 6e 74 61 | 74 69 6f 6e 2c 20 61 6e |plementa|tion, an|
|00000410| 64 0d 69 74 73 20 70 61 | 72 74 69 63 75 6c 61 72 |d.its pa|rticular|
|00000420| 20 71 75 69 72 6b 73 20 | 61 72 65 20 73 6f 6d 65 | quirks |are some|
|00000430| 74 69 6d 65 73 20 77 6f | 72 74 68 20 62 65 69 6e |times wo|rth bein|
|00000440| 67 20 6d 65 6e 74 69 6f | 6e 65 64 2c 20 65 73 70 |g mentio|ned, esp|
|00000450| 65 63 69 61 6c 6c 79 0d | 77 68 65 72 65 20 74 68 |ecially.|where th|
|00000460| 65 20 69 6d 70 6c 65 6d | 65 6e 74 61 74 69 6f 6e |e implem|entation|
|00000470| 20 69 6d 70 6f 73 65 73 | 20 61 64 64 69 74 69 6f | imposes| additio|
|00000480| 6e 61 6c 20 6c 69 6d 69 | 74 61 74 69 6f 6e 73 2e |nal limi|tations.|
|00000490| 20 20 54 68 65 72 65 66 | 6f 72 65 2c 0d 79 6f 75 | Theref|ore,.you|
|000004a0| 27 6c 6c 20 66 69 6e 64 | 20 73 68 6f 72 74 20 60 |'ll find| short `|
|000004b0| 60 69 6d 70 6c 65 6d 65 | 6e 74 61 74 69 6f 6e 20 |`impleme|ntation |
|000004c0| 6e 6f 74 65 73 27 27 20 | 73 70 72 69 6e 6b 6c 65 |notes'' |sprinkle|
|000004d0| 64 20 74 68 72 6f 75 67 | 68 6f 75 74 20 74 68 65 |d throug|hout the|
|000004e0| 0d 74 65 78 74 2e 0d 0d | 45 76 65 72 79 20 50 79 |.text...|Every Py|
|000004f0| 74 68 6f 6e 20 69 6d 70 | 6c 65 6d 65 6e 74 61 74 |thon imp|lementat|
|00000500| 69 6f 6e 20 63 6f 6d 65 | 73 20 77 69 74 68 20 61 |ion come|s with a|
|00000510| 20 6e 75 6d 62 65 72 20 | 6f 66 20 62 75 69 6c 74 | number |of built|
|00000520| 2d 69 6e 20 61 6e 64 0d | 73 74 61 6e 64 61 72 64 |-in and.|standard|
|00000530| 20 6d 6f 64 75 6c 65 73 | 2e 20 20 54 68 65 73 65 | modules|. These|
|00000540| 20 61 72 65 20 6e 6f 74 | 20 64 6f 63 75 6d 65 6e | are not| documen|
|00000550| 74 65 64 20 68 65 72 65 | 2c 20 62 75 74 20 69 6e |ted here|, but in|
|00000560| 20 74 68 65 20 73 65 70 | 61 72 61 74 65 0d 7b 5c | the sep|arate.{\|
|00000570| 65 6d 20 50 79 74 68 6f | 6e 20 4c 69 62 72 61 72 |em Pytho|n Librar|
|00000580| 79 20 52 65 66 65 72 65 | 6e 63 65 7d 20 64 6f 63 |y Refere|nce} doc|
|00000590| 75 6d 65 6e 74 2e 20 20 | 41 20 66 65 77 20 62 75 |ument. |A few bu|
|000005a0| 69 6c 74 2d 69 6e 20 6d | 6f 64 75 6c 65 73 20 61 |ilt-in m|odules a|
|000005b0| 72 65 0d 6d 65 6e 74 69 | 6f 6e 65 64 20 77 68 65 |re.menti|oned whe|
|000005c0| 6e 20 74 68 65 79 20 69 | 6e 74 65 72 61 63 74 20 |n they i|nteract |
|000005d0| 69 6e 20 61 20 73 69 67 | 6e 69 66 69 63 61 6e 74 |in a sig|nificant|
|000005e0| 20 77 61 79 20 77 69 74 | 68 20 74 68 65 20 6c 61 | way wit|h the la|
|000005f0| 6e 67 75 61 67 65 0d 64 | 65 66 69 6e 69 74 69 6f |nguage.d|efinitio|
|00000600| 6e 2e 0d 0d 5c 73 65 63 | 74 69 6f 6e 7b 4e 6f 74 |n...\sec|tion{Not|
|00000610| 61 74 69 6f 6e 7d 0d 0d | 54 68 65 20 64 65 73 63 |ation}..|The desc|
|00000620| 72 69 70 74 69 6f 6e 73 | 20 6f 66 20 6c 65 78 69 |riptions| of lexi|
|00000630| 63 61 6c 20 61 6e 61 6c | 79 73 69 73 20 61 6e 64 |cal anal|ysis and|
|00000640| 20 73 79 6e 74 61 78 20 | 75 73 65 20 61 20 6d 6f | syntax |use a mo|
|00000650| 64 69 66 69 65 64 20 42 | 4e 46 0d 67 72 61 6d 6d |dified B|NF.gramm|
|00000660| 61 72 20 6e 6f 74 61 74 | 69 6f 6e 2e 20 20 54 68 |ar notat|ion. Th|
|00000670| 69 73 20 75 73 65 73 20 | 74 68 65 20 66 6f 6c 6c |is uses |the foll|
|00000680| 6f 77 69 6e 67 20 73 74 | 79 6c 65 20 6f 66 20 64 |owing st|yle of d|
|00000690| 65 66 69 6e 69 74 69 6f | 6e 3a 0d 5c 69 6e 64 65 |efinitio|n:.\inde|
|000006a0| 78 7b 42 4e 46 7d 0d 5c | 69 6e 64 65 78 7b 67 72 |x{BNF}.\|index{gr|
|000006b0| 61 6d 6d 61 72 7d 0d 5c | 69 6e 64 65 78 7b 73 79 |ammar}.\|index{sy|
|000006c0| 6e 74 61 78 7d 0d 5c 69 | 6e 64 65 78 7b 6e 6f 74 |ntax}.\i|ndex{not|
|000006d0| 61 74 69 6f 6e 7d 0d 0d | 5c 62 65 67 69 6e 7b 76 |ation}..|\begin{v|
|000006e0| 65 72 62 61 74 69 6d 7d | 0d 6e 61 6d 65 3a 20 20 |erbatim}|.name: |
|000006f0| 20 20 20 20 20 20 20 20 | 20 6c 63 5f 6c 65 74 74 | | lc_lett|
|00000700| 65 72 20 28 6c 63 5f 6c | 65 74 74 65 72 20 7c 20 |er (lc_l|etter | |
|00000710| 22 5f 22 29 2a 0d 6c 63 | 5f 6c 65 74 74 65 72 3a |"_")*.lc|_letter:|
|00000720| 20 20 20 20 20 20 22 61 | 22 2e 2e 2e 22 7a 22 0d | "a|"..."z".|
|00000730| 5c 65 6e 64 7b 76 65 72 | 62 61 74 69 6d 7d 0d 0d |\end{ver|batim}..|
|00000740| 54 68 65 20 66 69 72 73 | 74 20 6c 69 6e 65 20 73 |The firs|t line s|
|00000750| 61 79 73 20 74 68 61 74 | 20 61 20 5c 76 65 72 62 |ays that| a \verb|
|00000760| 40 6e 61 6d 65 40 20 69 | 73 20 61 6e 20 5c 76 65 |@name@ i|s an \ve|
|00000770| 72 62 40 6c 63 5f 6c 65 | 74 74 65 72 40 20 66 6f |rb@lc_le|tter@ fo|
|00000780| 6c 6c 6f 77 65 64 20 62 | 79 0d 61 20 73 65 71 75 |llowed b|y.a sequ|
|00000790| 65 6e 63 65 20 6f 66 20 | 7a 65 72 6f 20 6f 72 20 |ence of |zero or |
|000007a0| 6d 6f 72 65 20 5c 76 65 | 72 62 40 6c 63 5f 6c 65 |more \ve|rb@lc_le|
|000007b0| 74 74 65 72 40 73 20 61 | 6e 64 20 75 6e 64 65 72 |tter@s a|nd under|
|000007c0| 73 63 6f 72 65 73 2e 20 | 20 41 6e 0d 5c 76 65 72 |scores. | An.\ver|
|000007d0| 62 40 6c 63 5f 6c 65 74 | 74 65 72 40 20 69 6e 20 |b@lc_let|ter@ in |
|000007e0| 74 75 72 6e 20 69 73 20 | 61 6e 79 20 6f 66 20 74 |turn is |any of t|
|000007f0| 68 65 20 73 69 6e 67 6c | 65 20 63 68 61 72 61 63 |he singl|e charac|
|00000800| 74 65 72 73 20 60 61 27 | 20 74 68 72 6f 75 67 68 |ters `a'| through|
|00000810| 20 60 7a 27 2e 0d 28 54 | 68 69 73 20 72 75 6c 65 | `z'..(T|his rule|
|00000820| 20 69 73 20 61 63 74 75 | 61 6c 6c 79 20 61 64 68 | is actu|ally adh|
|00000830| 65 72 65 64 20 74 6f 20 | 66 6f 72 20 74 68 65 20 |ered to |for the |
|00000840| 6e 61 6d 65 73 20 64 65 | 66 69 6e 65 64 20 69 6e |names de|fined in|
|00000850| 20 6c 65 78 69 63 61 6c | 20 61 6e 64 0d 67 72 61 | lexical| and.gra|
|00000860| 6d 6d 61 72 20 72 75 6c | 65 73 20 69 6e 20 74 68 |mmar rul|es in th|
|00000870| 69 73 20 64 6f 63 75 6d | 65 6e 74 2e 29 0d 0d 45 |is docum|ent.)..E|
|00000880| 61 63 68 20 72 75 6c 65 | 20 62 65 67 69 6e 73 20 |ach rule| begins |
|00000890| 77 69 74 68 20 61 20 6e | 61 6d 65 20 28 77 68 69 |with a n|ame (whi|
|000008a0| 63 68 20 69 73 20 74 68 | 65 20 6e 61 6d 65 20 64 |ch is th|e name d|
|000008b0| 65 66 69 6e 65 64 20 62 | 79 20 74 68 65 20 72 75 |efined b|y the ru|
|000008c0| 6c 65 29 0d 61 6e 64 20 | 61 20 63 6f 6c 6f 6e 2e |le).and |a colon.|
|000008d0| 20 20 41 20 76 65 72 74 | 69 63 61 6c 20 62 61 72 | A vert|ical bar|
|000008e0| 20 28 5c 76 65 72 62 40 | 7c 40 29 20 69 73 20 75 | (\verb@||@) is u|
|000008f0| 73 65 64 20 74 6f 20 73 | 65 70 61 72 61 74 65 0d |sed to s|eparate.|
|00000900| 61 6c 74 65 72 6e 61 74 | 69 76 65 73 3b 20 69 74 |alternat|ives; it|
|00000910| 20 69 73 20 74 68 65 20 | 6c 65 61 73 74 20 62 69 | is the |least bi|
|00000920| 6e 64 69 6e 67 20 6f 70 | 65 72 61 74 6f 72 20 69 |nding op|erator i|
|00000930| 6e 20 74 68 69 73 20 6e | 6f 74 61 74 69 6f 6e 2e |n this n|otation.|
|00000940| 20 20 41 0d 73 74 61 72 | 20 28 5c 76 65 72 62 40 | A.star| (\verb@|
|00000950| 2a 40 29 20 6d 65 61 6e | 73 20 7a 65 72 6f 20 6f |*@) mean|s zero o|
|00000960| 72 20 6d 6f 72 65 20 72 | 65 70 65 74 69 74 69 6f |r more r|epetitio|
|00000970| 6e 73 20 6f 66 20 74 68 | 65 20 70 72 65 63 65 64 |ns of th|e preced|
|00000980| 69 6e 67 20 69 74 65 6d | 3b 0d 6c 69 6b 65 77 69 |ing item|;.likewi|
|00000990| 73 65 2c 20 61 20 70 6c | 75 73 20 28 5c 76 65 72 |se, a pl|us (\ver|
|000009a0| 62 40 2b 40 29 20 6d 65 | 61 6e 73 20 6f 6e 65 20 |b@+@) me|ans one |
|000009b0| 6f 72 20 6d 6f 72 65 20 | 72 65 70 65 74 69 74 69 |or more |repetiti|
|000009c0| 6f 6e 73 2c 20 61 6e 64 | 20 61 0d 70 68 72 61 73 |ons, and| a.phras|
|000009d0| 65 20 65 6e 63 6c 6f 73 | 65 64 20 69 6e 20 73 71 |e enclos|ed in sq|
|000009e0| 75 61 72 65 20 62 72 61 | 63 6b 65 74 73 20 28 5c |uare bra|ckets (\|
|000009f0| 76 65 72 62 40 5b 20 5d | 40 29 20 6d 65 61 6e 73 |verb@[ ]|@) means|
|00000a00| 20 7a 65 72 6f 20 6f 72 | 20 6f 6e 65 0d 6f 63 63 | zero or| one.occ|
|00000a10| 75 72 72 65 6e 63 65 73 | 20 28 69 6e 20 6f 74 68 |urrences| (in oth|
|00000a20| 65 72 20 77 6f 72 64 73 | 2c 20 74 68 65 20 65 6e |er words|, the en|
|00000a30| 63 6c 6f 73 65 64 20 70 | 68 72 61 73 65 20 69 73 |closed p|hrase is|
|00000a40| 20 6f 70 74 69 6f 6e 61 | 6c 29 2e 20 20 54 68 65 | optiona|l). The|
|00000a50| 0d 5c 76 65 72 62 40 2a | 40 20 61 6e 64 20 5c 76 |.\verb@*|@ and \v|
|00000a60| 65 72 62 40 2b 40 20 6f | 70 65 72 61 74 6f 72 73 |erb@+@ o|perators|
|00000a70| 20 62 69 6e 64 20 61 73 | 20 74 69 67 68 74 6c 79 | bind as| tightly|
|00000a80| 20 61 73 20 70 6f 73 73 | 69 62 6c 65 3b 0d 70 61 | as poss|ible;.pa|
|00000a90| 72 65 6e 74 68 65 73 65 | 73 20 61 72 65 20 75 73 |renthese|s are us|
|00000aa0| 65 64 20 66 6f 72 20 67 | 72 6f 75 70 69 6e 67 2e |ed for g|rouping.|
|00000ab0| 20 20 4c 69 74 65 72 61 | 6c 20 73 74 72 69 6e 67 | Litera|l string|
|00000ac0| 73 20 61 72 65 20 65 6e | 63 6c 6f 73 65 64 20 69 |s are en|closed i|
|00000ad0| 6e 0d 71 75 6f 74 65 73 | 2e 20 20 57 68 69 74 65 |n.quotes|. White|
|00000ae0| 20 73 70 61 63 65 20 69 | 73 20 6f 6e 6c 79 20 6d | space i|s only m|
|00000af0| 65 61 6e 69 6e 67 66 75 | 6c 20 74 6f 20 73 65 70 |eaningfu|l to sep|
|00000b00| 61 72 61 74 65 20 74 6f | 6b 65 6e 73 2e 0d 52 75 |arate to|kens..Ru|
|00000b10| 6c 65 73 20 61 72 65 20 | 6e 6f 72 6d 61 6c 6c 79 |les are |normally|
|00000b20| 20 63 6f 6e 74 61 69 6e | 65 64 20 6f 6e 20 61 20 | contain|ed on a |
|00000b30| 73 69 6e 67 6c 65 20 6c | 69 6e 65 3b 20 72 75 6c |single l|ine; rul|
|00000b40| 65 73 20 77 69 74 68 20 | 6d 61 6e 79 0d 61 6c 74 |es with |many.alt|
|00000b50| 65 72 6e 61 74 69 76 65 | 73 20 6d 61 79 20 62 65 |ernative|s may be|
|00000b60| 20 66 6f 72 6d 61 74 74 | 65 64 20 61 6c 74 65 72 | formatt|ed alter|
|00000b70| 6e 61 74 69 76 65 6c 79 | 20 77 69 74 68 20 65 61 |natively| with ea|
|00000b80| 63 68 20 6c 69 6e 65 20 | 61 66 74 65 72 20 74 68 |ch line |after th|
|00000b90| 65 0d 66 69 72 73 74 20 | 62 65 67 69 6e 6e 69 6e |e.first |beginnin|
|00000ba0| 67 20 77 69 74 68 20 61 | 20 76 65 72 74 69 63 61 |g with a| vertica|
|00000bb0| 6c 20 62 61 72 2e 0d 0d | 49 6e 20 6c 65 78 69 63 |l bar...|In lexic|
|00000bc0| 61 6c 20 64 65 66 69 6e | 69 74 69 6f 6e 73 20 28 |al defin|itions (|
|00000bd0| 61 73 20 74 68 65 20 65 | 78 61 6d 70 6c 65 20 61 |as the e|xample a|
|00000be0| 62 6f 76 65 29 2c 20 74 | 77 6f 20 6d 6f 72 65 20 |bove), t|wo more |
|00000bf0| 63 6f 6e 76 65 6e 74 69 | 6f 6e 73 0d 61 72 65 20 |conventi|ons.are |
|00000c00| 75 73 65 64 3a 20 54 77 | 6f 20 6c 69 74 65 72 61 |used: Tw|o litera|
|00000c10| 6c 20 63 68 61 72 61 63 | 74 65 72 73 20 73 65 70 |l charac|ters sep|
|00000c20| 61 72 61 74 65 64 20 62 | 79 20 74 68 72 65 65 20 |arated b|y three |
|00000c30| 64 6f 74 73 20 6d 65 61 | 6e 20 61 20 63 68 6f 69 |dots mea|n a choi|
|00000c40| 63 65 0d 6f 66 20 61 6e | 79 20 73 69 6e 67 6c 65 |ce.of an|y single|
|00000c50| 20 63 68 61 72 61 63 74 | 65 72 20 69 6e 20 74 68 | charact|er in th|
|00000c60| 65 20 67 69 76 65 6e 20 | 28 69 6e 63 6c 75 73 69 |e given |(inclusi|
|00000c70| 76 65 29 20 72 61 6e 67 | 65 20 6f 66 20 41 53 43 |ve) rang|e of ASC|
|00000c80| 49 49 0d 63 68 61 72 61 | 63 74 65 72 73 2e 20 20 |II.chara|cters. |
|00000c90| 41 20 70 68 72 61 73 65 | 20 62 65 74 77 65 65 6e |A phrase| between|
|00000ca0| 20 61 6e 67 75 6c 61 72 | 20 62 72 61 63 6b 65 74 | angular| bracket|
|00000cb0| 73 20 28 5c 76 65 72 62 | 40 3c 2e 2e 2e 3e 40 29 |s (\verb|@<...>@)|
|00000cc0| 20 67 69 76 65 73 20 61 | 6e 0d 69 6e 66 6f 72 6d | gives a|n.inform|
|00000cd0| 61 6c 20 64 65 73 63 72 | 69 70 74 69 6f 6e 20 6f |al descr|iption o|
|00000ce0| 66 20 74 68 65 20 73 79 | 6d 62 6f 6c 20 64 65 66 |f the sy|mbol def|
|00000cf0| 69 6e 65 64 3b 20 65 2e | 67 2e 20 74 68 69 73 20 |ined; e.|g. this |
|00000d00| 63 6f 75 6c 64 20 62 65 | 20 75 73 65 64 0d 74 6f |could be| used.to|
|00000d10| 20 64 65 73 63 72 69 62 | 65 20 74 68 65 20 6e 6f | describ|e the no|
|00000d20| 74 69 6f 6e 20 6f 66 20 | 60 63 6f 6e 74 72 6f 6c |tion of |`control|
|00000d30| 20 63 68 61 72 61 63 74 | 65 72 27 20 69 66 20 6e | charact|er' if n|
|00000d40| 65 65 64 65 64 2e 0d 5c | 69 6e 64 65 78 7b 6c 65 |eeded..\|index{le|
|00000d50| 78 69 63 61 6c 20 64 65 | 66 69 6e 69 74 69 6f 6e |xical de|finition|
|00000d60| 73 7d 0d 5c 69 6e 64 65 | 78 7b 41 53 43 49 49 7d |s}.\inde|x{ASCII}|
|00000d70| 0d 0d 45 76 65 6e 20 74 | 68 6f 75 67 68 20 74 68 |..Even t|hough th|
|00000d80| 65 20 6e 6f 74 61 74 69 | 6f 6e 20 75 73 65 64 20 |e notati|on used |
|00000d90| 69 73 20 61 6c 6d 6f 73 | 74 20 74 68 65 20 73 61 |is almos|t the sa|
|00000da0| 6d 65 2c 20 74 68 65 72 | 65 20 69 73 20 61 20 62 |me, ther|e is a b|
|00000db0| 69 67 0d 64 69 66 66 65 | 72 65 6e 63 65 20 62 65 |ig.diffe|rence be|
|00000dc0| 74 77 65 65 6e 20 74 68 | 65 20 6d 65 61 6e 69 6e |tween th|e meanin|
|00000dd0| 67 20 6f 66 20 6c 65 78 | 69 63 61 6c 20 61 6e 64 |g of lex|ical and|
|00000de0| 20 73 79 6e 74 61 63 74 | 69 63 20 64 65 66 69 6e | syntact|ic defin|
|00000df0| 69 74 69 6f 6e 73 3a 0d | 61 20 6c 65 78 69 63 61 |itions:.|a lexica|
|00000e00| 6c 20 64 65 66 69 6e 69 | 74 69 6f 6e 20 6f 70 65 |l defini|tion ope|
|00000e10| 72 61 74 65 73 20 6f 6e | 20 74 68 65 20 69 6e 64 |rates on| the ind|
|00000e20| 69 76 69 64 75 61 6c 20 | 63 68 61 72 61 63 74 65 |ividual |characte|
|00000e30| 72 73 20 6f 66 20 74 68 | 65 0d 69 6e 70 75 74 20 |rs of th|e.input |
|00000e40| 73 6f 75 72 63 65 2c 20 | 77 68 69 6c 65 20 61 20 |source, |while a |
|00000e50| 73 79 6e 74 61 78 20 64 | 65 66 69 6e 69 74 69 6f |syntax d|efinitio|
|00000e60| 6e 20 6f 70 65 72 61 74 | 65 73 20 6f 6e 20 74 68 |n operat|es on th|
|00000e70| 65 20 73 74 72 65 61 6d | 20 6f 66 0d 74 6f 6b 65 |e stream| of.toke|
|00000e80| 6e 73 20 67 65 6e 65 72 | 61 74 65 64 20 62 79 20 |ns gener|ated by |
|00000e90| 74 68 65 20 6c 65 78 69 | 63 61 6c 20 61 6e 61 6c |the lexi|cal anal|
|00000ea0| 79 73 69 73 2e 20 20 41 | 6c 6c 20 75 73 65 73 20 |ysis. A|ll uses |
|00000eb0| 6f 66 20 42 4e 46 20 69 | 6e 20 74 68 65 20 6e 65 |of BNF i|n the ne|
|00000ec0| 78 74 0d 63 68 61 70 74 | 65 72 20 28 60 60 4c 65 |xt.chapt|er (``Le|
|00000ed0| 78 69 63 61 6c 20 41 6e | 61 6c 79 73 69 73 27 27 |xical An|alysis''|
|00000ee0| 29 20 61 72 65 20 6c 65 | 78 69 63 61 6c 20 64 65 |) are le|xical de|
|00000ef0| 66 69 6e 69 74 69 6f 6e | 73 3b 20 75 73 65 73 20 |finition|s; uses |
|00000f00| 69 6e 0d 73 75 62 73 65 | 71 75 65 6e 74 20 63 68 |in.subse|quent ch|
|00000f10| 61 70 74 65 72 73 20 61 | 72 65 20 73 79 6e 74 61 |apters a|re synta|
|00000f20| 63 74 69 63 20 64 65 66 | 69 6e 69 74 69 6f 6e 73 |ctic def|initions|
|00000f30| 2e 0d | |.. | |
+--------+-------------------------+-------------------------+--------+--------+