1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
|
%!PS-Adobe-2.0
%%DocumentFonts: (atend)
%%Title: F:\\LPT\\COMPR\\APP_A.DOC
%%Creator: Lotus Manuscript
%%For: EWvA, MRK
%%CreationDate: February 26, 1993
%%Pages: (atend)
%%BoundingBox: 0 0 595 841
%%EndComments
% PostScript Prologue (initialization) for Manuscript
% Copyright (c) 1985,1986,1987,1988 Lotus Development Corporation
% There is no user servicable code in this file.
% set timeouts to infinite
statusdict begin
0 setjobtimeout
/manualfeedtimeout 3600 def
/waittimeout 0 def
end
% correct bug correction in rev 41.0
/idiv{div cvi}bind def
% define User Dictionary
/msdict 300 dict def msdict begin
/bd{bind def}bind def
% Define commonly used things
/delay{usertime 5000 add{dup usertime lt{pop exit}if}loop}bd
/mfeed{statusdict begin /manualfeed true def end}bd
/afeed{statusdict begin /manualfeed false def end}bd
/bfeed{ afeed statusdict begin /setpapertray where
{pop setpapertray}{pop} ifelse end}bd
/dpi{0.24 dup scale}bd
% These two are called for each page
/inpage false def
/begpage{save dpi /inpage true def}bd
/endpage{inpage {restore showpage}if }bd
% for possible banner
/fileinfo {pop pop pop}bd
/enddocument {end} bd
% these are also used by eqn & gmf
/ld{load def}bd
/x/exch ld
/cu{300 mul 72 div}bd
/m/moveto ld
/t/translate ld
/rm/rmoveto ld
/cp/currentpoint ld
/st/stroke ld
/ln/lineto ld
/rlt/rlineto ld
/slw/setlinewidth ld
/ff/findfont ld
/scf/scalefont ld
/sf/setfont ld
/fs{x /pt x def ff pt cu scf sf}bd
% linedraw
/li{4 2 roll setlinewidth 3 1 roll moveto 0.0 rlineto st}bd
% outline factor
/olwid 40.0 def
% stroke width for outline
/uoslw {pt cu x div slw}bd
% relative horizontal move
/xm{x currentpoint pop sub 0.0 rmoveto}bd
% The basic show
/s/show ld
% move horizontal and show
/ms{xm s}bd
% variations
% outline show - first printer attribute
/ppss{dup cp 3 -1 roll false charpath st
x 3 -1 roll stringwidth pop add x moveto}bd
/pss{olwid uoslw { ( ) dup 0 4 -1 roll put ppss}forall}bd
/ps{pss}bd
/mps{xm ps}bd
% graybox show - second printer attribute
/gb{cp 3 -1 roll pt cu dup 4 div neg 0 x rm dup 0 x rlt x 0 rlt
neg 0 x rlt closepath currentgray .9 setgray fill setgray m}bd
/usi{dup stringwidth pop gb}bd
/us{usi s}bd
/xum{x cp pop sub dup gb 0 rmoveto}bd
% combinations of PD1 and PD2
/ups{usi pss}bd
/mups{xm ups}bd
/mus{xm us}bd
% define a new encoding vector (code page 850 based)
/PC 256 array def
StandardEncoding PC copy pop
/dotaccent/bullet
/quotesingle/quotedblleft/quotedblright/quotesinglbase
/quotedblbase/guilsinglleft/guilsinglright/.notdef
/ellipsis/perthousand/.notdef/.notdef/paragraph/section/dagger/daggerdbl
/OE/oe/fi/fl/endash/emdash/fraction/Ydieresis
PC 6 26 getinterval astore pop
/Ccedilla/udieresis/eacute/acircumflex/adieresis/agrave/aring/ccedilla
/ecircumflex/edieresis/egrave/idieresis/icircumflex/igrave/Adieresis/Aring
/Eacute/ae/AE/ocircumflex/odieresis/ograve/ucircumflex/ugrave
/ydieresis/Odieresis/Udieresis/oslash/sterling/Oslash/.notdef/florin
/aacute/iacute/oacute/uacute/ntilde/Ntilde/ordfeminine/ordmasculine
/questiondown/.notdef/.notdef/onehalf/onequarter/exclamdown/guillemotleft/guillemotright
/.notdef/.notdef/.notdef/.notdef/.notdef/Aacute/Acircumflex/Agrave
/.notdef/.notdef/.notdef/.notdef/.notdef/cent/yen/.notdef
/.notdef/grave/.notdef/circumflex/tilde/.notdef/atilde/Atilde
/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/currency
/eth/Eth/Ecircumflex/Edieresis/Egrave/dotlessi/Iacute/Icircumflex
/Idieresis/.notdef/.notdef/.notdef/.notdef/brokenbar/Igrave/.notdef
/Oacute/germandbls/Ocircumflex/Ograve/otilde/Otilde/.notdef/thorn
/Thorn/Uacute/Ucircumflex/Ugrave/yacute/Yacute/.notdef/acute
/.notdef/.notdef/.notdef/threequarters/paragraph/section/.notdef/cedilla
/ring/dieresis/periodcentered/onesuperior/threesuperior/twosuperior/.notdef/.notdef
PC 128 128 getinterval astore pop
% duplicate fonts with a new encoding vector
/recd 5 dict def
/pcft
{recd begin
/ncs PC def /nfn x def
/bfn x def /bfd bfn findfont def
/nf bfd maxlength dict def
bfd{x dup dup /FID ne x /Encoding ne and
{x nf 3 1 roll put}{pop pop}ifelse
}forall
nf/FontName nfn put
nf/Encoding ncs put
nfn nf definefont pop
end}bd
/fs{x /pt x def ff pt cu scf sf}bd
% used by eqn
/Times-Roman/TR pcft /Times-Bold/TRB pcft
/Times-Italic/TRI pcft /Times-BoldItalic/TRBI pcft
/Helvetica/HV pcft /Helvetica-Bold/HVB pcft
/Helvetica-Oblique/HVO pcft /Helvetica-BoldOblique/HVBO pcft
/Courier/CR pcft /Courier-Bold/CRB pcft
/Sym{/Symbol fs}bd
% Bit map image data decompression code
/xx 0 def /yy 0 def
/xbytes 0 def
/lbuf 1200 string def /obuf 600 string def
/bval <FFFEFCF8F0E0C080000103070F1F3F7F> def
/blacks 96 string def /whites 96 string def
0 1 95 {whites x 255 put} for
/dispatch [
{
dup 47 le {32 sub 4 bitshift x pop 1}{
dup 63 le {x pop 48 sub bval x get
3 copy put x 1 add x 0} {
dup 79 le {62 sub} {
80 sub { 3 copy put x 1 add x } repeat 0
}ifelse }ifelse }ifelse
}bind
{
32 sub add
3 copy put
x 1 add x 0
} bind
{
32 sub x pop add 255 0
}bind
{
32 sub x pop
3 copy getinterval
whites 0 3 index getinterval
x copy pop add 255 0
}bind
{
32 sub x pop
3 copy getinterval
blacks 0 3 index getinterval
x copy pop add 0 0
}bind
]def
% read a raster line and unpack
/readx{
obuf 0 255 0
currentfile lbuf readline pop
{x dispatch x get exec} forall
pop pop pop 0 xbytes getinterval}bd
/mspic{
/yy x def/xx x def
/xbytes xx 8 idiv def
xx yy 1 [xx 0 0 0 yy sub 0 yy]{readx}image}bd
/Helvetica/fA pcft/FA{/fA fs}bd
/Helvetica-Oblique/fAI pcft/FAI{/fAI fs}bd
/Helvetica-Bold/fAB pcft/FAB{/fAB fs}bd
/Helvetica-BoldOblique/fAIB pcft/FAIB{/fAIB fs}bd
/Times-Roman/fB pcft/FB{/fB fs}bd
/Times-Italic/fBI pcft/FBI{/fBI fs}bd
/Times-Bold/fBB pcft/FBB{/fBB fs}bd
/Times-BoldItalic/fBIB pcft/FBIB{/fBIB fs}bd
/Courier/fH pcft/FH{/fH fs}bd
/Courier-Oblique/fHI pcft/FHI{/fHI fs}bd
/Courier-Bold/fHB pcft/FHB{/fHB fs}bd
/Courier-BoldOblique/fHIB pcft/FHIB{/fHIB fs}bd
/ZapfChancery-MediumItalic/fL pcft/FL{/fL fs}bd
/ZapfChancery-MediumItalic/fLI pcft/FLI{/fLI fs}bd
/ZapfChancery-MediumItalic/fLB pcft/FLB{/fLB fs}bd
/ZapfChancery-MediumItalic/fLIB pcft/FLIB{/fLIB fs}bd
/AvantGarde-Book/fM pcft/FM{/fM fs}bd
/AvantGarde-BookOblique/fMI pcft/FMI{/fMI fs}bd
/AvantGarde-Demi/fMB pcft/FMB{/fMB fs}bd
/AvantGarde-DemiOblique/fMIB pcft/FMIB{/fMIB fs}bd
(F:\\LPT\\COMPR\\APP_A.DOC)(EWvA, MRK)(February 26, 1993)fileinfo
%%EndProlog
%%Page: 0 1
delay mfeed
begpage
12 FAB
880 3176 m
(Appendix A: Palindrome filter)s
12 FB
293 2969 m
(In)s
352(this)ms
442(appendix)ms
644(we)ms
720(illustrate)ms
913(the)ms
992(CLiP)ms
1116(style)ms
1228(of)ms
1288(literate)ms
1445(programming)ms
1735(by)ms
1803(a)ms
1843(program)ms
2030(to)ms
2087(filter)ms
12 FB
293 2909 m
(palindromic)s
551(lines)ms
662(from)ms
775(an)ms
839(input)ms
958(file.)ms
1054(Three)ms
1187(files)ms
1290(are)ms
1367(involved:)ms
1573(the)ms
1650(program)ms
1836(module)ms
2003(\()ms
11 FH
(PALIN-)s
11 FH
293 2849 m
(DROME.PAS)s
12 FB
(\),)s
582(a)ms
616(test)ms
698(file)ms
778(\()ms
11 FH
(TESTDATA.TXT)s
12 FB
(\))s
1154(and)ms
1238(a)ms
1273(command)ms
1483(file)ms
1562(\()ms
11 FH
(PALINDROME.COM)s
12 FB
(\))s
1993(to)ms
2044(run)ms
2123(the)ms
293 2789 m
(palindrome)s
533(filter.)ms
393 2729 m
(Subsections)s
646(A.1)ms
735(through)ms
905(A.7)ms
993(display)ms
1153(the)ms
1229(documentation)ms
1541(literally,)ms
1723(but)ms
1802(we)ms
1875(have)ms
1984(numbered)ms
293 2669 m
(the)s
366(code)ms
473(lines)ms
580(in)ms
631(the)ms
705(margin)ms
859(for)ms
930(easy)ms
1031(reference)ms
1230(from)ms
1339(the)ms
1413(main)ms
1526(text.)ms
12 FAB
293 2546 m
(A.1. Specification)s
12 FB
293 2459 m
(A)s
341(palindrome)ms
581(is)ms
627(a)ms
661(sentence)ms
846(with)ms
947(the)ms
1020(property)ms
1202(that)ms
1289(the)ms
1363(letters)ms
1497(from)ms
1607(left)ms
1686(to)ms
1737(right,)ms
1856(read)ms
1954(the)ms
2028(same)ms
2143(as)ms
293 2399 m
(from)s
410(right)ms
525(to)ms
585(left.)ms
685(In)ms
747(the)ms
828(comparison)ms
1082(uppercase)ms
1303(and)ms
1396(lowercase)ms
1616(letters)ms
1759(are)ms
1841(considered)ms
2078(to)ms
2137(be)ms
293 2339 m
(equivalent)s
510(and)ms
591(all)ms
650(other)ms
762(characters)ms
973(are)ms
1043(simply)ms
1189(ignored.)ms
1363(Hence)ms
1499(an)ms
1556(empty)ms
1690(sentence)ms
1871(is)ms
1913(a)ms
1944(palindrome.)ms
293 2279 m
(Other)s
419(examples)ms
620(are:)ms
8 FB
226 2198 m
(1)s
10 FH
368 2198 m
(\(************* #file "TESTDATA.TXT" #comment off *************\))s
8 FB
226 2156 m
(2)s
10 FH
368 2156 m
(Ada)s
8 FB
226 2115 m
(3)s
10 FH
368 2115 m
(1234567)s
8 FB
226 2073 m
(4)s
10 FH
368 2073 m
(Able was I, ere I saw Elba.)s
8 FB
226 2031 m
(5)s
10 FH
368 2031 m
(A man, a plan, a canal, Panama.)s
8 FB
226 1990 m
(6)s
10 FH
368 1990 m
(Norma is as selfless as I Am, Ron.)s
8 FB
226 1948 m
(7)s
10 FH
368 1948 m
(\(***************** End of TESTDATA.PAS ************************\))s
12 FB
293 1856 m
(The)s
384(program)ms
11 FH
567(PALINDROME)ms
12 FB
856(reads)ms
975(an)ms
1036(input)ms
1152(file,)ms
1245(filters)ms
1375(the)ms
1450(lines)ms
1558(that)ms
1647(are)ms
1721(palindromic)ms
1976(and)ms
2062(writes)ms
293 1796 m
(them)s
405(to)ms
456(an)ms
516(output)ms
656(file.)ms
12 FAB
293 1672 m
(A.2. Communication with the outside world)s
12 FB
293 1586 m
(The)s
389(program)ms
576(conforms)ms
784(to)ms
841(the)ms
921(general)ms
1086(template)ms
1277(of)ms
1337(a)ms
1377(Pascal)ms
1524(program.)ms
1724(We)ms
1812(introduce)ms
2019(the)ms
2098(files)ms
11 FH
293 1526 m
(IN_FILE)s
12 FB
499(and)ms
11 FH
585(OUT_FILE)ms
12 FB
818(to)ms
871(define)ms
1010(its)ms
1071(communication)ms
1395(with)ms
1498(the)ms
1573(outside)ms
1731(world.)ms
1874(The)ms
1965(actual)ms
2098(files)ms
293 1466 m
(have)s
399(to)ms
451(be)ms
511(specified)ms
704(at)ms
752(run-time.)ms
949(Thus)ms
1062(we)ms
1133(have)ms
8 FB
226 1385 m
(8)s
10 FH
368 1385 m
(\(***************** #file "PALINDROME.PAS" *********************\))s
8 FB
226 1343 m
(9)s
10 FH
368 1343 m
(\(****************************************************************\))s
8 FB
209 1301 m
(10)s
10 FH
368 1301 m
(\(* Program: Palindrome filter program. *\))s
8 FB
209 1260 m
(11)s
10 FH
368 1260 m
(\(* Purpose: To filter the palindromic lines from a given input *\))s
8 FB
209 1218 m
(12)s
10 FH
368 1218 m
(\(* file to a specified output file. *\))s
8 FB
209 1176 m
(13)s
10 FH
368 1176 m
(\(****************************************************************\))s
8 FB
209 1135 m
(14)s
10 FH
368 1135 m
(PROGRAM PALINDROME \(INPUT, OUTPUT, IN_FILE, OUT_FILE\);)s
8 FB
209 1093 m
(15)s
209 1051 m
(16)s
10 FH
368 1051 m
(\(******* Palindrome constants #multiple #comment off *******\))s
8 FB
209 1010 m
(17)s
10 FH
368 1010 m
(\(******* Palindrome types #multiple #comment off *******\))s
8 FB
209 968 m
(18)s
10 FH
368 968 m
(VAR)s
8 FB
209 926 m
(19)s
10 FH
368 926 m
( IN_FILE, OUT_FILE: TEXT;)s
8 FB
209 885 m
(20)s
10 FH
368 885 m
(\(******* Palindrome variables #multiple #comment off *******\))s
8 FB
209 843 m
(21)s
209 801 m
(22)s
10 FH
368 801 m
(BEGIN)s
8 FB
209 760 m
(23)s
10 FH
368 760 m
( RESET \(IN_FILE\);)s
8 FB
209 718 m
(24)s
10 FH
368 718 m
( REWRITE \(OUT_FILE\);)s
8 FB
209 676 m
(25)s
209 635 m
(26)s
10 FH
368 635 m
( \(***************** Palindrome \(body\) **********************\))s
8 FB
209 593 m
(27)s
10 FH
368 593 m
( \(** Copy the lines of the IN_FILE that are palindromic to **\))s
8 FB
209 551 m
(28)s
10 FH
368 551 m
( \(** the OUT_FILE. **\))s
8 FB
209 510 m
(29)s
10 FH
368 510 m
( \(************************************************************\))s
8 FB
209 468 m
(30)s
209 426 m
(31)s
10 FH
368 426 m
(END \(*PALINDROME*\).)s
8 FB
209 385 m
(32)s
10 FH
368 385 m
(\(******************* End of PALINDROME.PAS ********************\))s
8 FB
293 204 m
(The)s
353(CLiP)ms
431(Style)ms
508(of)ms
544(Literate)ms
656(Programming)ms
848(\(3.076,)ms
951(26-feb-93\))ms
12 FB
2075 204 m
( 1 )s
50 2 2130 216 li
50 2 2020 216 li
endpage
%%Page: 1 2
delay mfeed
begpage
12 FB
293 3179 m
(To)s
361(prepare)ms
523(the)ms
597(module)ms
759(for)ms
830(future)ms
962(declarations)ms
1216(of)ms
1270(constants)ms
1469(and)ms
1553(types)ms
1671(we)ms
1742(have)ms
8 FB
209 3098 m
(33)s
10 FH
368 3098 m
(\(******* Palindrome constants #leader #quick *******\))s
8 FB
209 3056 m
(34)s
10 FH
368 3056 m
(CONST)s
8 FB
209 3015 m
(35)s
10 FH
368 3015 m
(\(******* Palindrome types #leader #quick *******\))s
8 FB
209 2973 m
(36)s
10 FH
368 2973 m
(TYPE)s
12 FAB
293 2861 m
(A.3. Processing of the files)s
12 FB
293 2774 m
(The)s
382(program)ms
563(processes)ms
11 FH
766(IN_FILE)ms
12 FB
970(line)ms
1057(by)ms
1119(line.)ms
1218(The)ms
1307(idea)ms
1402(is)ms
1447(to)ms
1498(buffer)ms
1632(an)ms
1691(exact)ms
1808(copy)ms
1917(of)ms
1970(the)ms
2043(current)ms
293 2714 m
(line)s
380(in)ms
11 FH
432(IN_LINE)ms
12 FB
(,)s
650(while)ms
774(at)ms
823(the)ms
897(same)ms
1013(time)ms
1115(its)ms
1175(letters)ms
1310(are)ms
1384(buffered)ms
1566(in)ms
11 FH
1618(LETTERS)ms
12 FB
(.)s
1836(So)ms
11 FH
1901(LETTERS)ms
12 FB
2107(will)ms
293 2654 m
(be)s
351(empty)ms
487(if)ms
529(the)ms
601(line)ms
687(holds)ms
807(no)ms
868(letters)ms
1002(at)ms
1049(all,)ms
1123(in)ms
1173(which)ms
1306(case)ms
1403(the)ms
1476(line)ms
1562(is)ms
1607(considered)ms
1834(to)ms
1884(be)ms
1943(palindromic)ms
293 2594 m
(by)s
355(definition.)ms
393 2534 m
(We)s
473(choose)ms
622(the)ms
694(buffers)ms
11 FH
847(IN_LINE)ms
12 FB
1050(and)ms
11 FH
1133(LETTERS)ms
12 FB
1336(to)ms
1386(be)ms
1444(of)ms
1497(the)ms
1568(same)ms
1682(type,)ms
11 FH
1791(TEXT_LINE)ms
12 FB
(,)s
2062(which)ms
293 2474 m
(we)s
363(will)ms
454(not)ms
530(specify)ms
687(in)ms
738(detail)ms
862(right)ms
969(now.)ms
1080(For)ms
1162(this)ms
1247(purpose)ms
1417(we)ms
1488(introduce)ms
1690(a)ms
1724(type)ms
11 FH
1823(ABSTRACT)ms
12 FB
(.)s
8 FB
209 2393 m
(37)s
10 FH
368 2393 m
(\(******* Palindrome types #quick *******\))s
8 FB
209 2351 m
(38)s
10 FH
368 2351 m
( ABSTRACT = \(DEFINED, UNDEFINED\);)s
11 FH
293 2259 m
(TEXT_LINE)s
12 FB
553(will)ms
644(temporarily)ms
890(be)ms
951(declared)ms
11 FH
1133(ABSTRACT)ms
12 FB
1366(and)ms
1452(its)ms
1512(details)ms
1656(will)ms
1747(be)ms
1807(defined)ms
1970(later.)ms
2085(Thus)ms
293 2199 m
(the)s
366(declaration)ms
601(of)ms
11 FH
655(TEXT_LINE)ms
8 FB
209 2118 m
(39)s
10 FH
368 2118 m
(\(******* Palindrome types *******\))s
8 FB
209 2076 m
(40)s
10 FH
368 2076 m
(\(******* Declaration of TEXT_LINE *******\))s
8 FB
209 2035 m
(41)s
10 FH
368 2035 m
(\(***************** End of Palindrome types ********************\))s
12 FB
293 1942 m
(is)s
338(temporarily)ms
584(satisfied)ms
763(with)ms
865(the)ms
938(type)ms
11 FH
1037(ABSTRACT)ms
12 FB
(.)s
8 FB
209 1861 m
(42)s
10 FH
368 1861 m
(\(******* Declaration of TEXT_LINE #quick #default *******\))s
8 FB
209 1820 m
(43)s
10 FH
368 1820 m
( TEXT_LINE = ABSTRACT;)s
12 FB
293 1727 m
(The)s
383(declaration)ms
617(for)ms
688(the)ms
762(variables)ms
11 FH
955(IN_LINE)ms
12 FB
1160(and)ms
11 FH
1245(LETTERS)ms
12 FB
1450(becomes)ms
8 FB
209 1646 m
(44)s
10 FH
368 1646 m
(\(******* Palindrome variables #quick *******\))s
8 FB
209 1605 m
(45)s
10 FH
368 1605 m
( IN_LINE,)s
8 FB
209 1563 m
(46)s
10 FH
368 1563 m
( LETTERS: TEXT_LINE;)s
12 FB
293 1471 m
(We)s
377(have)ms
486(to)ms
540(test)ms
11 FH
625(LETTERS)ms
12 FB
832(in)ms
886(order)ms
1007(to)ms
1061(decide)ms
1206(whether)ms
1382(or)ms
1439(not)ms
11 FH
1518(IN_LINE)ms
12 FB
1725(contains)ms
1907(a)ms
1944(palindrome.)ms
293 1411 m
(The)s
383(result)ms
506(of)ms
561(this)ms
645(test)ms
727(is)ms
773(flagged)ms
936(by)ms
11 FH
998(IS_PALINDROME)ms
12 FB
(,)s
1381(for)ms
1451(which)ms
1586(we)ms
1657(introduce)ms
1858(the)ms
1932(declaration)ms
8 FB
209 1330 m
(47)s
10 FH
368 1330 m
(\(******* Palindrome variables #quick *******\))s
8 FB
209 1288 m
(48)s
10 FH
368 1288 m
( IS_PALINDROME: BOOLEAN;)s
12 FB
293 1196 m
(Now)s
402(the)ms
476(body)ms
588(of)ms
642(the)ms
716(Palindrome)ms
959(filter)ms
1069(may)ms
1167(be)ms
1227(expanded)ms
1431(as)ms
8 FB
209 1115 m
(49)s
10 FH
368 1115 m
( \(***************** Palindrome \(body\) **********************\))s
8 FB
209 1073 m
(50)s
10 FH
368 1073 m
( \(** Copy the lines of the IN_FILE that are palindromic to **\))s
8 FB
209 1031 m
(51)s
10 FH
368 1031 m
( \(** the OUT_FILE. **\))s
8 FB
209 990 m
(52)s
10 FH
368 990 m
( WHILE NOT EOF \(IN_FILE\) DO)s
8 FB
209 948 m
(53)s
10 FH
368 948 m
( BEGIN)s
8 FB
209 906 m
(54)s
10 FH
368 906 m
( \(***************** Palindrome \(1\) *********************\))s
8 FB
209 865 m
(55)s
10 FH
368 865 m
( \(** Read a line from IN_FILE into IN_LINE. The letters **\))s
8 FB
209 823 m
(56)s
10 FH
368 823 m
( \(** of this line are copied to LETTERS. **\))s
8 FB
209 781 m
(57)s
10 FH
368 781 m
( \(********************************************************\))s
8 FB
209 740 m
(58)s
209 698 m
(59)s
10 FH
368 698 m
( READLN \(IN_FILE\);)s
8 FB
209 656 m
(60)s
209 615 m
(61)s
10 FH
368 615 m
( \(***************** Palindrome \(2\) *********************\))s
8 FB
209 573 m
(62)s
10 FH
368 573 m
( \(** Test palindromicity of LETTERS. Set IS_PALINDROME **\))s
8 FB
209 531 m
(63)s
10 FH
368 531 m
( \(** to reflect the result of the test. **\))s
8 FB
209 490 m
(64)s
10 FH
368 490 m
( \(********************************************************\))s
8 FB
209 448 m
(65)s
293 204 m
(The)s
353(CLiP)ms
431(Style)ms
508(of)ms
544(Literate)ms
656(Programming)ms
848(\(3.076,)ms
951(26-feb-93\))ms
12 FB
2075 204 m
( 2 )s
50 2 2130 216 li
50 2 2020 216 li
endpage
%%Page: 2 3
delay mfeed
begpage
8 FB
209 3188 m
(66)s
10 FH
368 3188 m
( IF IS_PALINDROME THEN)s
8 FB
209 3146 m
(67)s
10 FH
368 3146 m
( BEGIN)s
8 FB
209 3105 m
(68)s
10 FH
368 3105 m
( \(***************** Palindrome \(3\) *****************\))s
8 FB
209 3063 m
(69)s
10 FH
368 3063 m
( \(** Write IN_LINE to OUT_FILE. **\))s
8 FB
209 3021 m
(70)s
10 FH
368 3021 m
( \(****************************************************\))s
8 FB
209 2980 m
(71)s
209 2938 m
(72)s
10 FH
368 2938 m
( WRITELN \(OUT_FILE\);)s
8 FB
209 2896 m
(73)s
10 FH
368 2896 m
( END \(*IF*\);)s
8 FB
209 2855 m
(74)s
10 FH
368 2855 m
( END \(*WHILE*\);)s
8 FB
209 2813 m
(75)s
10 FH
368 2813 m
( \(************* End of Palindrome \(body\) *******************\))s
12 FAB
293 2701 m
(A.4. Choosing the structure of )s
11 FH
(IN_LINE)s
12 FAB
( and )s
11 FH
(LETTERS)s
12 FB
293 2614 m
(Before)s
440(we)ms
510(can)ms
591(proceed)ms
761(we)ms
831(need)ms
937(to)ms
988(establish)ms
1175(a)ms
1209(structure)ms
1395(for)ms
1465(the)ms
1538(objects)ms
11 FH
1691(IN_LINE)ms
12 FB
1896(and)ms
11 FH
1980(LETTERS)ms
12 FB
(.)s
293 2554 m
(Thus)s
410(we)ms
486(define)ms
11 FH
628(TEXT_LINE)ms
12 FB
893(as)ms
952(a)ms
991(structure)ms
1184(with)ms
1290(two)ms
1382(components.)ms
1654(The)ms
1749(first)ms
1847(component)ms
2087(is)ms
2137(an)ms
293 2494 m
(array,)s
11 FH
422(CHARS)ms
12 FB
(,)s
587(which)ms
724(contains)ms
906(the)ms
982(characters)ms
1199(to)ms
1253(be)ms
1315(buffered.)ms
1511(The)ms
1604(second)ms
1758(component,)ms
11 FH
2007(LENGTH)ms
12 FB
(,)s
293 2434 m
(indicates)s
483(which)ms
617(part)ms
707(of)ms
761(the)ms
834(array)ms
949(is)ms
995(actually)ms
1165(occupied.)ms
1371(The)ms
1461(maximum)ms
1676(number)ms
1841(of)ms
1895(characters)ms
2110(that)ms
293 2374 m
(can)s
373(be)ms
432(buffered)ms
613(by)ms
674(the)ms
747(structure)ms
933(is)ms
978(determined)ms
1214(by)ms
1276(the)ms
1348(length,)ms
11 FH
1497(MAX_L)ms
12 FB
(,)s
1659(of)ms
1712(the)ms
1784(array.)ms
11 FH
1911(MAX_L)ms
12 FB
2060(serves)ms
293 2314 m
(as)s
347(an)ms
406(implementation)ms
733(parameter.)ms
8 FB
209 2233 m
(76)s
10 FH
368 2233 m
(\(******* Palindrome constants #quick *******\))s
8 FB
209 2191 m
(77)s
10 FH
368 2191 m
( MAX_L = 132;)s
8 FB
209 2150 m
(78)s
209 2108 m
(79)s
10 FH
368 2108 m
(\(******* Declaration of TEXT_LINE #quick *******\))s
8 FB
209 2066 m
(80)s
10 FH
368 2066 m
( TEXT_LINE = RECORD)s
8 FB
209 2025 m
(81)s
10 FH
368 2025 m
( CHARS: ARRAY[1..MAX_L] OF CHAR;)s
8 FB
209 1983 m
(82)s
10 FH
368 1983 m
( LENGTH: 0..MAX_L;)s
8 FB
209 1941 m
(83)s
10 FH
368 1941 m
( END \(*RECORD*\);)s
12 FAB
293 1829 m
(A.5. Reading a line)s
12 FB
293 1742 m
(For)s
381(efficiency)ms
599(reasons)ms
768(we)ms
845(fill)ms
11 FH
922(IN_LINE)ms
12 FB
1133(and)ms
11 FH
1224(LETTERS)ms
12 FB
1435(simultaneously.)ms
1769(Therefore)ms
1985(we)ms
2062(buffer)ms
293 1682 m
(every)s
416(character)ms
612(that)ms
699(is)ms
745(read)ms
844(from)ms
11 FH
953(IN_FILE)ms
12 FB
1158(in)ms
1210(the)ms
1283(variable)ms
11 FH
1457(IN_CHAR)ms
12 FB
(.)s
8 FB
209 1601 m
(84)s
10 FH
368 1601 m
(\(******* Palindrome variables #quick *******\))s
8 FB
209 1560 m
(85)s
10 FH
368 1560 m
( IN_CHAR: CHAR;)s
12 FB
293 1467 m
(Only)s
402(when)ms
11 FH
520(IN_CHAR)ms
12 FB
723(turns)ms
832(out)ms
906(to)ms
955(be)ms
1011(a)ms
1043(letter)ms
1156(it)ms
1193(is)ms
1237(copied)ms
1380(to)ms
11 FH
1428(LETTERS)ms
12 FB
(.)s
1643(Since)ms
1764(this)ms
1846(process)ms
2005(is)ms
2049(crucial)ms
293 1407 m
(for)s
363(the)ms
437(overall)ms
588(operation,)ms
802(we)ms
873(make)ms
994(provisions)ms
1215(for)ms
1285(some)ms
1403(debugging)ms
1627(code)ms
1734(here.)ms
8 FB
209 1326 m
(86)s
10 FH
368 1326 m
( \(***************** Palindrome \(1\) *********************\))s
8 FB
209 1285 m
(87)s
10 FH
368 1285 m
( \(** Read a line from IN_FILE into IN_LINE. The letters **\))s
8 FB
209 1243 m
(88)s
10 FH
368 1243 m
( \(** of this line are copied to LETTERS. **\))s
8 FB
209 1201 m
(89)s
10 FH
368 1201 m
( IN_LINE.LENGTH := 0;)s
8 FB
209 1160 m
(90)s
10 FH
368 1160 m
( LETTERS.LENGTH := 0;)s
8 FB
209 1118 m
(91)s
10 FH
368 1118 m
( WITH IN_LINE DO)s
8 FB
209 1076 m
(92)s
10 FH
368 1076 m
( WHILE NOT EOLN \(IN_FILE\) DO)s
8 FB
209 1035 m
(93)s
10 FH
368 1035 m
( BEGIN)s
8 FB
209 993 m
(94)s
10 FH
368 993 m
( READ \(IN_FILE, IN_CHAR\);)s
8 FB
209 951 m
(95)s
10 FH
368 951 m
( LENGTH := LENGTH + 1;)s
8 FB
209 910 m
(96)s
10 FH
368 910 m
( CHARS[LENGTH] := IN_CHAR;)s
8 FB
209 868 m
(97)s
10 FH
368 868 m
( IF IN_CHAR IN ['A'..'Z', 'a'..'z'] THEN)s
8 FB
209 826 m
(98)s
10 FH
368 826 m
( WITH LETTERS DO)s
8 FB
209 785 m
(99)s
10 FH
368 785 m
( BEGIN)s
8 FB
193 743 m
(100)s
10 FH
368 743 m
( LENGTH := LENGTH + 1;)s
8 FB
193 701 m
(101)s
10 FH
368 701 m
( CHARS[LENGTH] := IN_CHAR;)s
8 FB
193 660 m
(102)s
10 FH
368 660 m
( END \(*WITH/IF*\);)s
8 FB
193 618 m
(103)s
10 FH
368 618 m
( END \(*WHILE/WITH*\);)s
8 FB
193 576 m
(104)s
193 535 m
(105)s
10 FH
368 535 m
( \(********************* Palindrome \(test\) **************\))s
8 FB
193 493 m
(106)s
10 FH
368 493 m
( \(** Check contents of IN_LINE and LETTERS. #optional **\))s
8 FB
193 451 m
(107)s
10 FH
368 451 m
( \(********************************************************\))s
8 FB
193 410 m
(108)s
193 368 m
(109)s
10 FH
368 368 m
( \(***************** End of Palindrome \(1\) **************\))s
8 FB
293 204 m
(The)s
353(CLiP)ms
431(Style)ms
508(of)ms
544(Literate)ms
656(Programming)ms
848(\(3.076,)ms
951(26-feb-93\))ms
12 FB
2075 204 m
( 3 )s
50 2 2130 216 li
50 2 2020 216 li
endpage
%%Page: 3 4
delay mfeed
begpage
12 FAB
293 3176 m
(A.6. Testing for palindromicity)s
12 FB
293 3089 m
(We)s
385(test)ms
478(the)ms
562(palindromicity)ms
879(of)ms
11 FH
944(LETTERS)ms
12 FB
1160(in)ms
1222(two)ms
1320(steps.)ms
1455(First)ms
1570(we)ms
1651(transform)ms
1869(the)ms
1953(contents)ms
2143(of)ms
11 FH
293 3029 m
(LETTERS)s
12 FB
501(to)ms
556(uppercase)ms
773(and)ms
861(then)ms
963(we)ms
1038(compare)ms
1226(the)ms
1304(characters)ms
1523(of)ms
11 FH
1581(LETTERS)ms
12 FB
1789(pairwise.)ms
1988(The)ms
2082(com-)ms
293 2969 m
(parison)s
453(is)ms
500(done)ms
611(starting)ms
774(with)ms
876(the)ms
951(most)ms
1062(outside)ms
1219(characters)ms
1436(and)ms
1521(progressing)ms
1768(inward.)ms
1933(The)ms
2024(string)ms
2151(is)ms
293 2909 m
(assumed)s
478(a)ms
514(palindrome)ms
756(until)ms
861(the)ms
936(opposite)ms
1119(is)ms
1166(proven)ms
1318(through)ms
1487(a)ms
1523(pair)ms
1615(of)ms
1670(different)ms
1856(characters.)ms
2084(With)ms
293 2849 m
(the)s
366(local)ms
476(counter)ms
8 FB
193 2768 m
(110)s
10 FH
368 2768 m
(\(******* Palindrome variables #quick *******\))s
8 FB
193 2726 m
(111)s
10 FH
368 2726 m
( I: INTEGER;)s
12 FB
293 2634 m
(we)s
363(keep)ms
470(track)ms
583(of)ms
637(the)ms
710(comparing)ms
937(process.)ms
1112(Now)ms
11 FH
1221(Palindrome \(2\))ms
12 FB
1619(can)ms
1701(be)ms
1761(expanded)ms
1965(as)ms
8 FB
193 2553 m
(112)s
10 FH
368 2553 m
( \(***************** Palindrome \(2\) *********************\))s
8 FB
193 2511 m
(113)s
10 FH
368 2511 m
( \(** Test palindromicity of LETTERS. Set IS_PALINDROME **\))s
8 FB
193 2470 m
(114)s
10 FH
368 2470 m
( \(** to reflect the result of the test. **\))s
8 FB
193 2428 m
(115)s
10 FH
368 2428 m
( WITH LETTERS DO)s
8 FB
193 2386 m
(116)s
10 FH
368 2386 m
( BEGIN)s
8 FB
193 2345 m
(117)s
10 FH
368 2345 m
( \(* Transform lowercase to uppercase. *\))s
8 FB
193 2303 m
(118)s
10 FH
368 2303 m
( FOR I := 1 TO LENGTH DO)s
8 FB
193 2261 m
(119)s
10 FH
368 2261 m
( IF CHARS[I] IN ['a'..'z'])s
8 FB
193 2220 m
(120)s
10 FH
368 2220 m
( THEN CHARS[I] :=)s
8 FB
193 2178 m
(121)s
10 FH
368 2178 m
( CHR\(ORD\(CHARS[I]\) - ORD\('a'\) + ORD\('A'\)\);)s
8 FB
193 2136 m
(122)s
193 2095 m
(123)s
10 FH
368 2095 m
( \(* Perform the palindromicity test. *\))s
8 FB
193 2053 m
(124)s
10 FH
368 2053 m
( IS_PALINDROME := TRUE;)s
8 FB
193 2011 m
(125)s
10 FH
368 2011 m
( I := 1;)s
8 FB
193 1970 m
(126)s
10 FH
368 1970 m
( WHILE IS_PALINDROME AND \(I <= LENGTH DIV 2\) DO)s
8 FB
193 1928 m
(127)s
10 FH
368 1928 m
( IF CHARS[I] = CHARS[LENGTH-I+1] THEN)s
8 FB
193 1886 m
(128)s
10 FH
368 1886 m
( I := I + 1)s
8 FB
193 1845 m
(129)s
10 FH
368 1845 m
( ELSE)s
8 FB
193 1803 m
(130)s
10 FH
368 1803 m
( IS_PALINDROME := FALSE;)s
8 FB
193 1761 m
(131)s
10 FH
368 1761 m
( END \(*WITH*\);)s
8 FB
193 1720 m
(132)s
10 FH
368 1720 m
( \(***************** End of Palindrome \(2\) **************\))s
12 FAB
293 1607 m
(A.7. Writing the palindrome)s
12 FB
293 1521 m
(The)s
383(only)ms
484(remaining)ms
699(action)ms
834(is)ms
880(to)ms
931(write)ms
1047(the)ms
1120(contents)ms
1299(of)ms
11 FH
1354(IN_LINE)ms
12 FB
(.)s
1571(Again)ms
1706(we)ms
1777(need)ms
1883(a)ms
1918(local)ms
2028(counter)ms
8 FB
193 1440 m
(133)s
10 FH
368 1440 m
(\(******* Palindrome variables #quick *******\))s
8 FB
193 1398 m
(134)s
10 FH
368 1398 m
( J: INTEGER;)s
12 FB
293 1306 m
(The)s
383(writing)ms
540(proceeds)ms
730(straight)ms
892(forward.)ms
8 FB
193 1225 m
(135)s
10 FH
368 1225 m
( \(***************** Palindrome \(3\) *****************\))s
8 FB
193 1183 m
(136)s
10 FH
368 1183 m
( \(** Write IN_LINE to OUT_FILE. **\))s
8 FB
193 1141 m
(137)s
10 FH
368 1141 m
( WITH IN_LINE DO)s
8 FB
193 1100 m
(138)s
10 FH
368 1100 m
( BEGIN)s
8 FB
193 1058 m
(139)s
10 FH
368 1058 m
( FOR J := 1 TO LENGTH DO)s
8 FB
193 1016 m
(140)s
10 FH
368 1016 m
( WRITE \(OUT_FILE, CHARS[J]\);)s
8 FB
193 975 m
(141)s
10 FH
368 975 m
( END \(*WITH*\);)s
8 FB
193 933 m
(142)s
10 FH
368 933 m
( \(************* End of Palindrome \(3\) **************\))s
12 FAB
293 821 m
(A.8. Running the Palindrome filter)s
12 FB
293 734 m
(To)s
365(run)ms
449(the)ms
527(program)ms
713(in)ms
769(a)ms
808(VAX/VMS)ms
1055(environment)ms
1325(the)ms
1403(following)ms
1614(command)ms
1829(procedure)ms
2045(is)ms
2096(con-)ms
293 674 m
(venient.)s
8 FB
193 593 m
(143)s
10 FH
368 593 m
(\(********* #file "PALINDROME.COM" #comment off ***************\))s
8 FB
193 551 m
(144)s
10 FH
368 551 m
($!***************************************************************!)s
8 FB
193 510 m
(145)s
10 FH
368 510 m
($! Run PALINDROME. Input file and output file are parameters. *!)s
8 FB
193 468 m
(146)s
10 FH
368 468 m
($! Par1: Specification of input file. *!)s
8 FB
193 426 m
(147)s
10 FH
368 426 m
($! Par2: Specification of output file. *!)s
8 FB
193 385 m
(148)s
10 FH
368 385 m
($!***************************************************************!)s
8 FB
293 204 m
(The)s
353(CLiP)ms
431(Style)ms
508(of)ms
544(Literate)ms
656(Programming)ms
848(\(3.076,)ms
951(26-feb-93\))ms
12 FB
2075 204 m
( 4 )s
50 2 2130 216 li
50 2 2020 216 li
endpage
%%Page: 4 5
delay mfeed
begpage
8 FB
193 3188 m
(149)s
10 FH
368 3188 m
($DEFINE IN_FILE 'P1)s
8 FB
193 3146 m
(150)s
10 FH
368 3146 m
($DEFINE OUT_FILE 'P2)s
8 FB
193 3105 m
(151)s
10 FH
368 3105 m
(RUN PALIND)s
8 FB
193 3063 m
(152)s
10 FH
368 3063 m
(\(***************** End of PALINDROME.COM **********************\))s
8 FB
293 204 m
(The)s
353(CLiP)ms
431(Style)ms
508(of)ms
544(Literate)ms
656(Programming)ms
848(\(3.076,)ms
951(26-feb-93\))ms
12 FB
2075 204 m
( 5 )s
50 2 2130 216 li
50 2 2020 216 li
endpage
%%Trailer
enddocument
%%Pages: 5
%%DocumentFonts:
%%+ Helvetica-Bold
%%+ Times-Roman
%%+ Courier
%%EOF
|