1982 lines
68 KiB
Plaintext
1982 lines
68 KiB
Plaintext
,...
|
|
$$$$
|
|
$$$$T""P$$$ba, ,gd&P""T&bg. ,gd&P""T&bg.
|
|
ggggggggggg $$$$ $$$$$b d$$$$ $$$$b d$$$$ $$$$$b ggggggggggg
|
|
""""""""""" $$$$ $$$$$$ $$$$$ $$$$$ $$$$$bxxP&$$&P """""""""""
|
|
$$$$ $$$$$$ T$$$$ $$$$P T$$$$
|
|
$$$"""""" " """" $$$$$$ "T&$bxxd$&P" "T&$bxx$$$$$' " """"""$$$
|
|
""" """""" """
|
|
ggg "The HOE c0de Issue" ggg
|
|
$$$ by - Various Artists $$$
|
|
$$$ $$$
|
|
$$$ [ HOE E-Zine #935 -- 12/05/99 -- http://www.hoe.nu ] .,$$$
|
|
`"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""'
|
|
|
|
To be cute, I asked various e'zine folks I know to send HOE
|
|
something for a programming code compilation. Here's what I got.
|
|
|
|
## AUTHOR LANGUAGE TITLE
|
|
== ====== ======== =====
|
|
|
|
01 Uberfizzgig GW-BASIC 2.02 "Useful Things To Know"
|
|
02 Jamesy PERL "caitlin.pl"
|
|
03 AltRocks C "Simple Command Line File Copy"
|
|
04 Cyn Java "Hangman Fun"
|
|
05 gd & zab C "makegore.c"
|
|
06 Ior C "Tic-Tac-Toe, One In A Row"
|
|
07 Ior HC11 Assembler "dsp.s"
|
|
08 AIDS PERL "poe.pl"
|
|
09 Trilobyte C++ "Tim's Special World"
|
|
10 Trilobyte AREXX "AREXX-based HOE Issue Commenter"
|
|
11 Gaurdian Tcl/Eggdrop "Hooker's Babble"
|
|
12 Gaurdian Tcl/Eggdrop "Eggdrop Defintions By Question"
|
|
|
|
##########
|
|
## [01] ##
|
|
###########################################################################
|
|
## FILENAME: "Useful Things To Know"
|
|
## LANGUAGE: GW-BASIC 2.02
|
|
## AUTHOR: Uberfizzgig
|
|
## COMMENTS: Ten years ago, I wrote a basic program called "Useful Things
|
|
## To Know". It was a reference/encyclopedia program. Here it
|
|
## is in its entirity. Enjoy.
|
|
###########################################################################
|
|
|
|
GW-BASIC 2.02
|
|
(C) Copyright Microsoft 1983,1984
|
|
TANDY 1000 GWBASIC 2.02
|
|
Tandy Version 01.02.01
|
|
Licensed to Tandy Corporation
|
|
60573 Bytes free
|
|
Ok
|
|
LOAD"UTTK.BAS"
|
|
LIST
|
|
50 WIDTH 80
|
|
60 COLOR 2,0,0
|
|
70 CLS
|
|
445 PRINT "Useful Things To Know."
|
|
450 PRINT
|
|
455 PRINT "Select Catagory."
|
|
460 PRINT
|
|
465 PRINT "1. Numbers / Letters"
|
|
470 PRINT "2. Abbreviations"
|
|
475 PRINT "3. Road Abbreviations"
|
|
480 PRINT "4. Conversion Table"
|
|
485 PRINT "5. Time Measure"
|
|
490 PRINT "6. Miscellaneous Measures"
|
|
495 PRINT "7. Math Stuff"
|
|
500 PRINT "8. Solar System"
|
|
505 PRINT "9. Presidents"
|
|
510 PRINT "10. United States"
|
|
511 PRINT "11. Menu"
|
|
512 PRINT "12. End"
|
|
515 COLOR 1,0:PRINT "Catagory No.";:INPUT N
|
|
516 COLOR 2,0
|
|
520 IF N= 1 THEN 580
|
|
525 IF N= 2 THEN 600
|
|
530 IF N= 3 THEN 680
|
|
535 IF N= 4 THEN 725
|
|
540 IF N= 5 THEN 900
|
|
550 IF N= 6 THEN 975
|
|
555 IF N= 7 THEN 1030
|
|
560 IF N= 8 THEN 1170
|
|
565 IF N= 9 THEN 1700
|
|
570 IF N= 10 THEN 3475
|
|
571 IF N= 11 THEN 450
|
|
572 IF N= 12 THEN 4055
|
|
573 GOTO 450
|
|
580 CLS
|
|
581 PRINT "Numbers / Letters"
|
|
585 PRINT "0,1,2,3,4,5,6,7,8,9 A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,"
|
|
590 PRINT "X,Y,Z a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z"
|
|
595 GOTO 515
|
|
600 CLS
|
|
601 PRINT "Abbreviations"
|
|
605 PRINT "in= inches yd= yards ft= feet mi= miles"
|
|
610 PRINT "tsp= teaspoon Tbsp= tablespoon c= cups oz= ounces"
|
|
615 PRINT "lb= pound pt= pints fl.oz= fluid ounces qt= quarts gal= gallons"
|
|
620 PRINT
|
|
625 PRINT "mm= millimeter cm= centimeter dm= decimeter m= meter"
|
|
630 PRINT "dkm= dekameter hm= hectometer km= kilometer"
|
|
635 PRINT"ml=milliliter cl= centiliter dl= deciliter l= liter dkl= dekaliter"
|
|
640 PRINT "hl= hectoliter kl= kiloliter"
|
|
645 PRINT "mg= milligram cg= centigram dg= decigram g= gram dkg= dekagram"
|
|
650 PRINT "hg= hectogram kg= kilogram"
|
|
655 PRINT "ha= hectares t= tonnes (1,000 kg)"
|
|
670 GOTO 515
|
|
680 CLS
|
|
681 PRINT "Road Abbreviations"
|
|
685 PRINT "Avenue: Ave Alley: Aly Arcade: Arc Boulevard: Blvd Branch: Br"
|
|
690 PRINT "Bypass: Byp Causeway: Cswy Center: Ctr Circle: Cir Court: Ct"
|
|
695 PRINT "Crescent: Cres Drive: Dr Expressway: Expy Extention: Ext"
|
|
700 PRINT "Freeway: Fwy Gardens: Gdns Grove: Grv Heights: Hts Highway: Hwy"
|
|
705 PRINT "Lane: Ln Place: Pl Plaza: Plz Point: Pt Road: Rd Square: Sq"
|
|
710 PRINT "Street: St Terrace: Ter Trail: Trl Turnpike: Tpke Viaduct: Via";
|
|
715 PRINT " Vista: Vis"
|
|
720 GOTO 515
|
|
725 CLS
|
|
726 PRINT "Conversion Table"
|
|
730 PRINT "LENGTH"
|
|
735 PRINT " mm* 0.04= in in* 2.54= cm"
|
|
740 PRINT " cm* 0.4 = in ft* 30.48= cm"
|
|
745 PRINT " m* 3.3 = ft yd* 0.9 = m"
|
|
750 PRINT " m* 1.1 = yd mi* 1.6 = km"
|
|
755 PRINT " km* 0.6 = mi"
|
|
760 PRINT
|
|
765 PRINT "AREA"
|
|
770 PRINT " cm* 0.6 = in in* 6.5 = cm"
|
|
775 PRINT " m* 1.2 = yd ft* 0.09= m"
|
|
780 PRINT " km* 0.4 = mi yd* 0.8 = m"
|
|
785 PRINT " ha* 2.5 = acres mi* 2.6 = km"
|
|
790 PRINT " acres* 0.4= ha"
|
|
795 PRINT
|
|
800 PRINT "MASS"
|
|
805 PRINT " g* 0.035= oz oz* 28 = g"
|
|
810 PRINT " kg* 2.2 = lb lbs* 0.45= kg"
|
|
815 PRINT " t* 1.1 = ton tons* 0.9= t"
|
|
820 PRINT "MORE";:INPUT J
|
|
825 PRINT "VOLUME"
|
|
830 PRINT " ml* 0.03= fl oz tsp* 5= ml"
|
|
835 PRINT " l* 2.1 = pt Tbsp* 15= ml"
|
|
840 PRINT " l* 1.06= qt fl oz* 30= ml"
|
|
845 PRINT " l* 0.26= gal c* 0.24 = l"
|
|
850 PRINT " m* 35 = ft pt* 0.47 = l"
|
|
855 PRINT " m* 1.3 = yd qt* 0.95 = l"
|
|
860 PRINT " gal* 3.8 = l"
|
|
865 PRINT " ft* 0.03 = m"
|
|
870 PRINT " yd* 0.76 = m"
|
|
875 PRINT
|
|
880 PRINT "TEMPERATURE"
|
|
885 PRINT " F to C: C= 5/9 (F- 32)"
|
|
890 PRINT " C to F: F= 9/5 (C+ 32)"
|
|
895 GOTO 515
|
|
900 CLS
|
|
901 PRINT "Time Measure"
|
|
905 PRINT "60 sec = 1 min 60 min = 1 h 24 h = 1 day 7 days = 1 week"
|
|
910 PRINT "28, 30, or 31 days = 1 month 12 months = 1 yr 365 days = 1 yr"
|
|
915 PRINT "366 days = 1 leap year 10 yrs = 1 decade 100 yrs = 1 century"
|
|
920 PRINT "10 decades = 1 century"
|
|
925 PRINT
|
|
930 PRINT "Sun.= Sunday Mon.= Monday Tues.= Tuesday Wed.= Wednesday"
|
|
935 PRINT "Thurs.= Thursday Fri.= Friday Sat.= Saturday"
|
|
940 PRINT
|
|
945 PRINT "January= Jan. 31 days Feberuary= Feb. 28 or 29 days"
|
|
950 PRINT "March= Mar. 31 days April= Apr. 30 days May= 31 days"
|
|
955 PRINT "June= 30 days July= 31 days August= Aug. 31 days"
|
|
960 PRINT "September= Sept. 30 days October= Oct. 31 days"
|
|
965 PRINT "November= Nov. 30 days December= Dec. 31 days"
|
|
970 GOTO 515
|
|
975 CLS
|
|
976 PRINT "Misc. Measure"
|
|
980 PRINT "2 pt = 1 qt 8 qt = 1 peck (pk) 4 pk = 1 bushel (bu)"
|
|
985 PRINT "1 cord = 128 ft 4 gills (gi) = 1 pt 4 qt = 1 gal"
|
|
990 PRINT "31 1/2 gal = 1 barrel (bbl) 2 bbl = 1 hogshead (hhd)"
|
|
995 PRINT "12 in = 1 ft 3 ft = 1 yd 16 1/2 ft (5 1/2 yd) = 1 rod"
|
|
1000 PRINT "660 ft = 1 furlong 320 rods (5,280 ft) = 1 mile"
|
|
1005 PRINT "12 units = 1 dozen (doz) 12 doz = 1 gross (gr)"
|
|
1010 PRINT "12 gr = 1 great gross 20 units = 1 score"
|
|
1015 PRINT "4 score and 7 yrs = 87 yrs 1 hand = 4 in 1 fathom = 6 ft"
|
|
1020 PRINT "1 knot = 6080 ft 3 knots = 1 league"
|
|
1025 GOTO 515
|
|
1030 CLS
|
|
1031 PRINT "Math Stuff"
|
|
1035 PRINT "addition: + plus subtraction: - minus multiplication: * times"
|
|
1040 PRINT "division: / divided by equals: = greater than: > less than: <"
|
|
1045 PRINT "decimal point: . parenthesis: ( ) brackets: [ ]"
|
|
1050 PRINT "solution set: { } pi= 3.14159265358... variables: a, b, c ..."
|
|
1055 PRINT
|
|
1060 PRINT "Parenthesis First"
|
|
1065 PRINT "Exponents Outside"
|
|
1070 PRINT "Multiplication Inside"
|
|
1075 PRINT "Division Last"
|
|
1080 PRINT "Addition"
|
|
1085 PRINT "Subtraction Use FOIL when multiplying 2 binomials"
|
|
1090 PRINT
|
|
1095 PRINT "MORE";:INPUT Z
|
|
1100 PRINT
|
|
1105 PRINT "PROPERTIES"
|
|
1110 PRINT "Communitive: a+b = b+a Associative: (a+b)+c = a+(b+c)"
|
|
1115 PRINT "Distributive: a(b+c) = ab+ac Symmetric: a=b & b=a"
|
|
1120 PRINT "Reflexive: a=a Transitive: if a=b & b=c then a=c"
|
|
1125 PRINT
|
|
1130 PRINT "MORE";:INPUT U
|
|
1135 PRINT
|
|
1140 PRINT "FORMULAS"
|
|
1145 PRINT " rate * time = distance diameter * pi = circumference"
|
|
1150 PRINT " diameter * 0.7854 = area length * width = area"
|
|
1155 PRINT " length * width * height = volume"
|
|
1160 PRINT " 2length + 2width = perimiter"
|
|
1165 GOTO 515
|
|
1170 CLS
|
|
1171 PRINT "Solar System"
|
|
1175 PRINT "SUN"
|
|
1176 PRINT "Diameter: 865,000 miles"
|
|
1177 PRINT "Surface Temperature: 10,300 degrees F."
|
|
1178 PRINT "Rotation Time: 25.4 days"
|
|
1179 PRINT "Atmospheric Gasses: 75% H, 24% He, 1% Other"
|
|
1180 PRINT "Sun Spots- cool, dark spots of atmospheric disturbance"
|
|
1185 PRINT "Solar Wind- Stream of particles given off by the sun"
|
|
1190 PRINT "Solar Flare- giant wave of plasma that emmits X rays"
|
|
1195 PRINT "MORE";:INPUT V
|
|
1200 PRINT
|
|
1205 PRINT "MERCURY"
|
|
1210 PRINT "Diameter: 3,032 miles"
|
|
1215 PRINT "Surface Temp.: sunlit: 950 F. dark: -340 F."
|
|
1220 PRINT "Rotation time: 59 days"
|
|
1225 PRINT "Revolution Time: 88 days"
|
|
1230 PRINT "Atmospheric Gasses: argon, neon, helium"
|
|
1235 PRINT "Explored By: Mariner 10"
|
|
1240 PRINT "Distance from sun: 35,980,000 miles"
|
|
1245 PRINT "MORE";:INPUT V
|
|
1250 PRINT
|
|
1255 PRINT "VENUS"
|
|
1260 PRINT "Diameter: 7,520 miles"
|
|
1265 PRINT "Surface Temperature: 980 F."
|
|
1270 PRINT "Rotation Time: 243 days"
|
|
1275 PRINT "Revolution Time: 225 days"
|
|
1280 PRINT "Atmospheric Gasses: sulfuric acid, carbon monoxide, water vapor"
|
|
1285 PRINT "Explored By: Mariner 2, Mariner 5, Mariner 10, Pioneer 1"
|
|
1290 PRINT " Pioneer 2, Venera 13, Venera 14"
|
|
1295 PRINT "Distance from sun: 67,200,000 miles"
|
|
1300 PRINT "MORE";:INPUT V
|
|
1305 PRINT
|
|
1310 PRINT "EARTH"
|
|
1315 PRINT "Diameter: 7,926 miles"
|
|
1320 PRINT "Rotation Time: 23.93 hours"
|
|
1325 PRINT "Revolution Time: 365 days"
|
|
1330 PRINT "Atmospheric Gasses: nitrogen, oxygen, carbon dioxide, other"
|
|
1335 PRINT "Distance from sun: 92,960,000 miles"
|
|
1340 PRINT "Moons: 1"
|
|
1345 PRINT "MORE";:INPUT V
|
|
1350 PRINT
|
|
1355 PRINT "MARS"
|
|
1360 PRINT "Diameter: 4,212 miles"
|
|
1365 PRINT "Rotation Time: 24.62 hours"
|
|
1370 PRINT "Revolution Time: 1.88 years"
|
|
1375 PRINT "Atmospheric Gasses: mostly carbon dioxide "
|
|
1380 PRINT "Explored By: Mariner 4, Mariner 9, Mars 2, Mars 3, Viking 1"
|
|
1385 PRINT " Viking 2"
|
|
1390 PRINT "Distance from sun: 141,680,000 miles"
|
|
1395 PRINT "Moons: 2"
|
|
1400 PRINT "MORE";:INPUT V
|
|
1405 PRINT
|
|
1410 PRINT "ASTEROID BELT"
|
|
1415 PRINT "Various sizes of rock orbiting the sun between Mars and Jupiter."
|
|
1420 PRINT "MORE";:INPUT V
|
|
1425 PRINT
|
|
1430 PRINT "JUPITER"
|
|
1435 PRINT "Diameter: 88,700 miles"
|
|
1440 PRINT "Rotation Time: 10 hours"
|
|
1445 PRINT "Revolution Time: 11.86 years"
|
|
1450 PRINT "Atmospheric Gasses: H, He, Other"
|
|
1455 PRINT "Explored By: Pioneer 10, Pioneer 11, Voyager 1, Voyager 2"
|
|
1460 PRINT " In Dec. 1995, Galileo"
|
|
1465 PRINT "Distance from sun: 483,700,000 miles"
|
|
1470 PRINT "Moons: 16 possibly 18"
|
|
1475 PRINT "Rings: 1"
|
|
1480 PRINT "MORE";:INPUT V
|
|
1485 PRINT
|
|
1490 PRINT "SATURN"
|
|
1495 PRINT "Diameter: 75,100 miles
|
|
1500 PRINT "Rotation Time: 11 hours"
|
|
1505 PRINT "Revolution Time: 84 years"
|
|
1510 PRINT "Atmospheric Gasses: hydrogen, helium, other"
|
|
1515 PRINT "Explored By: Pioneer 10, Pioneer 11, Voyager 1, Voyager 2"
|
|
1520 PRINT "Distance from sun: 886,740,000 miles"
|
|
1525 PRINT "Moons: 21 possibly 23"
|
|
1530 PRINT "Rings: about 1,000"
|
|
1535 PRINT "MORE";:INPUT V
|
|
1540 PRINT
|
|
1545 PRINT "URANUS"
|
|
1550 PRINT "Diameter: 32,600 miles"
|
|
1555 PRINT "Rotation Time: 16 hours"
|
|
1560 PRINT "Revolution Time: 84 years"
|
|
1565 PRINT "Explored By: Voyager 2"
|
|
1570 PRINT "Distance from sun: 1,783,170,000 miles"
|
|
1575 PRINT "Moons: 15"
|
|
1580 PRINT "Rings: 9"
|
|
1585 PRINT "MORE";:INPUT V
|
|
1590 PRINT
|
|
1595 PRINT "NEPTUNE"
|
|
1600 PRINT "Diameter: 27,700 miles"
|
|
1605 PRINT "Rotation Time: 18.5 hours"
|
|
1610 PRINT "Revolution Time: 164.8 years"
|
|
1615 PRINT "Explored By: Voyager 2"
|
|
1620 PRINT "Distance from sun: 2,794,190,000 miles"
|
|
1625 PRINT "Moons: 8"
|
|
1630 PRINT "Rings: 5"
|
|
1635 PRINT "MORE";:INPUT V
|
|
1640 PRINT
|
|
1645 PRINT "PLUTO"
|
|
1650 PRINT "Diameter: 1,860"
|
|
1655 PRINT "Rotation Time: 6.93 days"
|
|
1660 PRINT "Revolution Time: 247 years"
|
|
1662 PRINT "Distance from sun: 3,706,780,000 miles"
|
|
1665 PRINT "Moons: 1 possibly more"
|
|
1670 PRINT "MORE";:INPUT V
|
|
1675 PRINT
|
|
1680 PRINT "COMETS"
|
|
1685 PRINT "Balls of rock and/or ice. Elliptical orbits around sun."
|
|
1690 PRINT"Particles break off and are pushed back by solar wind to form a tail"
|
|
1695 GOTO 515
|
|
1700 CLS
|
|
1701 PRINT "Presidents"
|
|
1705 PRINT "1. George Washington"
|
|
1710 PRINT "Vice President.........John Adams"
|
|
1715 PRINT "Party..................None"
|
|
1720 PRINT "Term of office.........1789-1797"
|
|
1725 PRINT "Wife...................Martha Custis"
|
|
1730 PRINT "Senator / Congressman..No"
|
|
1735 PRINT "Coinage / Dollar.......Quarter, $1"
|
|
1740 PRINT
|
|
1745 PRINT "2. John Adams"
|
|
1750 PRINT "Vice President.........Thomas Jefferson"
|
|
1755 PRINT "Party..................Federalist"
|
|
1760 PRINT "Term of office.........1797-1801"
|
|
1765 PRINT "Wife...................Abigail Smith"
|
|
1770 PRINT "Senator / Congressman..No"
|
|
1775 PRINT "Coinage / Dollar.......None"
|
|
1785 PRINT
|
|
1790 PRINT "3. Thomas Jefferson"
|
|
1795 PRINT "Vice President.........Aaron Burr, George Clinton"
|
|
1800 PRINT "Party..................Democratic-Republican"
|
|
1805 PRINT "Term of office.........1801-1809"
|
|
1810 PRINT "Wife...................Martha Skelton"
|
|
1815 PRINT "Senator / Congressman..No"
|
|
1820 PRINT "Coinage / Dollar.......Nickel, $2"
|
|
1825 PRINT "MORE";:INPUT G
|
|
1830 PRINT "4. James Madison"
|
|
1835 PRINT "Vice President.........George Clinton, Elbridge Gerry"
|
|
1840 PRINT "Party..................Democratic-Republican"
|
|
1845 PRINT "Term of office.........1809-1817"
|
|
1850 PRINT "Wife...................Dorthea Payne Todd"
|
|
1855 PRINT "Senator / Congressman..Yes"
|
|
1860 PRINT "Coinage / Dollar.......$5,000"
|
|
1867 PRINT
|
|
1870 PRINT "5. James Monroe"
|
|
1875 PRINT "Vice President.........Daniel D. Tompkins"
|
|
1880 PRINT "Party..................Democratic-Republican"
|
|
1885 PRINT "Term of office.........1817-1825"
|
|
1890 PRINT "Wife...................Elizabeth Kortwright"
|
|
1895 PRINT "Senator / Congressman..Yes"
|
|
1900 PRINT "Coinage / Dollar.......None"
|
|
1905 PRINT
|
|
1910 PRINT "6. John Quincy Adams"
|
|
1915 PRINT "Vice President.........John C. Calhoun"
|
|
1920 PRINT "Party..................Democratic-Republican"
|
|
1925 PRINT "Term of office.........1825-1829"
|
|
1930 PRINT "Wife...................Louisa Johnson"
|
|
1935 PRINT "Senator / Congressman..Yes"
|
|
1940 PRINT "Coinage / Dollar.......None"
|
|
1941 PRINT "MORE";:INPUT G
|
|
1945 PRINT
|
|
1950 PRINT "7. Andrew Jackson"
|
|
1955 PRINT "Vice President.........John C. Calhoun, Martin Van Buren"
|
|
1960 PRINT "Party..................Democratic-Republican"
|
|
1965 PRINT "Term of office.........1829-1837"
|
|
1970 PRINT "Wife...................Rachel Robards"
|
|
1975 PRINT "Senator / Congressman..Yes"
|
|
1980 PRINT "Coinage / Dollar.......$20"
|
|
1985 PRINT
|
|
1990 PRINT "8. Martin Van Buren"
|
|
1995 PRINT "Vice President.........Richard M. Johnson"
|
|
2000 PRINT "Party..................Democrat"
|
|
2005 PRINT "Term of office.........1837-1841"
|
|
2010 PRINT "Wife...................Hannah Hoes"
|
|
2015 PRINT "Senator / Congressman..Yes"
|
|
2020 PRINT "Coinage / Dollar.......None"
|
|
2030 PRINT
|
|
2035 PRINT "9. William Henery Harrison"
|
|
2040 PRINT "Vice President.........John Tyler"
|
|
2045 PRINT "Party..................Whig"
|
|
2047 PRINT "Term of office.........1841"
|
|
2050 PRINT "Wife...................Anna Symmes"
|
|
2055 PRINT "Senator / Congressman..Yes"
|
|
2060 PRINT "Coinage / Dollar.......None"
|
|
2065 PRINT "MORE";:INPUT G
|
|
2070 PRINT "10. John Tyler"
|
|
2075 PRINT "Vice President.........None"
|
|
2080 PRINT "Party..................Whig"
|
|
2085 PRINT "Term of office.........1841-1845"
|
|
2090 PRINT "Wife...................Letitra Christian, Julia Gardner"
|
|
2095 PRINT "Senator / Congressman..Yes"
|
|
2100 PRINT "Coinage / Dollar.......None"
|
|
2110 PRINT
|
|
2115 PRINT "11. James K. Polk"
|
|
2120 PRINT "Vice President.........George M. Dallas"
|
|
2125 PRINT "Party..................Democrat"
|
|
2130 PRINT "Term of office.........1845-1849"
|
|
2135 PRINT "Wife...................Sarah Childress"
|
|
2140 PRINT "Senator / Congressman..Yes"
|
|
2145 PRINT "Coinage / Dollar.......None"
|
|
2150 PRINT
|
|
2155 PRINT "12. Zachary Taylor"
|
|
2160 PRINT "Vice President.........Millard Fillmore"
|
|
2165 PRINT "Party..................Whig"
|
|
2170 PRINT "Term of office.........1849-1850"
|
|
2175 PRINT "Wife...................Margaret Smith"
|
|
2180 PRINT "Senator / Congressman..No"
|
|
2185 PRINT "Coinage / Dollar.......None"
|
|
2195 PRINT "MORE";:INPUT G
|
|
2200 PRINT "13. Millard Fillmore"
|
|
2205 PRINT "Vice President.........None"
|
|
2210 PRINT "Party..................Whig"
|
|
2215 PRINT "Term of office.........1850-1853"
|
|
2220 PRINT "Wife...................Abigail Powers, Caroline McIntosh"
|
|
2225 PRINT "Senator / Congressman..Yes"
|
|
2230 PRINT "Coinage / Dollar.......None"
|
|
2235 PRINT
|
|
2240 PRINT "14. Franklin Pierce"
|
|
2245 PRINT "Vice President.........William R. King"
|
|
2250 PRINT "Party..................Democrat"
|
|
2255 PRINT "Term of office.........1853-1857"
|
|
2260 PRINT "Wife...................Jane Appleton"
|
|
2265 PRINT "Senator / Congressman..Yes"
|
|
2270 PRINT "Coinage / Dollar.......None"
|
|
2280 PRINT
|
|
2285 PRINT "15. James Buchanan"
|
|
2290 PRINT "Vice President.........John C. Breckinridge"
|
|
2295 PRINT "Party..................Democrat"
|
|
2300 PRINT "Term of office.........1857-1861"
|
|
2305 PRINT "Wife...................None"
|
|
2310 PRINT "Senator / Congressman..Yes"
|
|
2315 PRINT "Coinage / Dollar.......None"
|
|
2320 PRINT "MORE";:INPUT G
|
|
2325 PRINT "16. Abraham Lincoln"
|
|
2330 PRINT "Vice President.........Hannibal Hamlin, Andrew Johnson"
|
|
2335 PRINT "Party..................Republican"
|
|
2340 PRINT "Term of office.........1861-1865"
|
|
2345 PRINT "Wife...................Mary Todd"
|
|
2350 PRINT "Senator / Congressman..Yes"
|
|
2355 PRINT "Coinage / Dollar.......Penny, $5"
|
|
2360 PRINT "MORE";:INPUT G
|
|
2365 PRINT
|
|
2370 PRINT "17. Andrew Johnson"
|
|
2375 PRINT "Vice President.........None"
|
|
2380 PRINT "Party..................Democrat"
|
|
2385 PRINT "Term of office.........1865-1869"
|
|
2390 PRINT "Wife...................Eliza McCardle"
|
|
2395 PRINT "Senator / Congressman..Yes"
|
|
2400 PRINT "Coinage / Dollar.......None"
|
|
2405 PRINT
|
|
2410 PRINT "18. Ulysses S. Grant"
|
|
2415 PRINT "Vice President.........Schuyler Colfax"
|
|
2420 PRINT "Party..................Republican"
|
|
2425 PRINT "Term of office.........1869-1877"
|
|
2430 PRINT "Wife...................Julia Dent"
|
|
2435 PRINT "Senator / Congressman..No"
|
|
2440 PRINT "Coinage / Dollar.......$50"
|
|
2445 PRINT
|
|
2450 PRINT "19. Rutherford B. Hayes"
|
|
2455 PRINT "Vice President.........William A. Wheeler"
|
|
2460 PRINT "Party..................Republican"
|
|
2465 PRINT "Term of office.........1877-1881"
|
|
2470 PRINT "Wife...................Lucy Webb"
|
|
2475 PRINT "Senator / Congressman..Yes"
|
|
2480 PRINT "Coinage / Dollar.......None"
|
|
2485 PRINT "MORE";:INPUT G
|
|
2490 PRINT
|
|
2495 PRINT "20. James A. Garfield"
|
|
2500 PRINT "Vice President.........Chester A. Arthur"
|
|
2505 PRINT "Party..................Republican"
|
|
2510 PRINT "Term of office.........1881"
|
|
2515 PRINT "Wife ..................Lucietia Rudolph"
|
|
2520 PRINT "Senator / Congressman..Yes"
|
|
2525 PRINT "Coinage / Dollar.......None"
|
|
2530 PRINT
|
|
2535 PRINT "21. Chester A. Arthur"
|
|
2540 PRINT "Vice President.........None"
|
|
2545 PRINT "Party..................Republican"
|
|
2550 PRINT "Term of office.........1881-1885"
|
|
2555 PRINT "Wife...................Ellen Herndon"
|
|
2560 PRINT "Senator / Congressman..No"
|
|
2565 PRINT "Coinage / Dollar.......None"
|
|
2570 PRINT
|
|
2575 PRINT "22. S. Grover Cleveland"
|
|
2580 PRINT "Vice President.........Thomas A. Hendricks"
|
|
2585 PRINT "Party..................Democrat"
|
|
2590 PRINT "Term of office.........1885-1889"
|
|
2595 PRINT "Wife...................Frances Folsom"
|
|
2600 PRINT "Senator / Congressman..No"
|
|
2605 PRINT "Coinage / Dollar.......$1,000"
|
|
2610 PRINT "MORE";:INPUT G
|
|
2615 PRINT
|
|
2620 PRINT "23. Benjamin Harrison"
|
|
2625 PRINT "Vice President.........Levi P. Morton"
|
|
2630 PRINT "Party..................Republican"
|
|
2633 PRINT "Term of office.........1889-1893"
|
|
2635 PRINT "Wife...................Caroline Scott, Mary Scott Dimmick"
|
|
2640 PRINT "Senator / Congressman..No"
|
|
2645 PRINT "Coinage / Dollar.......None"
|
|
2650 PRINT
|
|
2655 PRINT "24. S. Grover Cleveland"
|
|
2660 PRINT "Vice President.........Adlai E. Stevenson"
|
|
2665 PRINT "Party..................Democrat"
|
|
2670 PRINT "Term of office.........1893-1897"
|
|
2675 PRINT "Wife...................Frances Folsom"
|
|
2680 PRINT "Senator / Congressman..No"
|
|
2685 PRINT "Coinage / Dollar.......$1,000"
|
|
2690 PRINT
|
|
2695 PRINT "25. William McKinley"
|
|
2700 PRINT "Vice President.........Theodore Roosevelt"
|
|
2705 PRINT "Party..................Republican"
|
|
2710 PRINT "Term of office.........1879-1901"
|
|
2715 PRINT "Wife...................Ida Saxton"
|
|
2720 PRINT "Senator / Congressman..Yes"
|
|
2725 PRINT "Coinage / Dollar.......$500"
|
|
2730 PRINT "MORE";:INPUT G
|
|
2735 PRINT
|
|
2740 PRINT "26. Theodore Roosevelt"
|
|
2745 PRINT "Vice President.........None. Charles W. Fairbanks"
|
|
2750 PRINT "Party..................Republican"
|
|
2755 PRINT "Term of office.........1901-1909"
|
|
2760 PRINT "Wife...................Alice Lee, Edith Carow"
|
|
2765 PRINT "Senator / Congressman..No"
|
|
2770 PRINT "Coinage / Dollar.......None"
|
|
2775 PRINT
|
|
2780 PRINT "27. William Howard Taft"
|
|
2785 PRINT "Vice President.........James S. Sherman"
|
|
2790 PRINT "Party..................Republican"
|
|
2795 PRINT "Term of office.........1909-1913"
|
|
2800 PRINT "Wife...................Helen Harron"
|
|
2805 PRINT "Senator / Congressman..No"
|
|
2810 PRINT "Coinage / Dollar.......None"
|
|
2815 PRINT
|
|
2820 PRINT "28. T. Woodrow Wilson"
|
|
2825 PRINT "Vice President.........Thomas R. Marshall"
|
|
2830 PRINT "Party..................Democrat"
|
|
2835 PRINT "Term of office.........1913-1921"
|
|
2840 PRINT "Wife...................Edith Galt"
|
|
2845 PRINT "Senator / Congressman..No"
|
|
2850 PRINT "Coinage / Dollar.......$100,000"
|
|
2855 PRINT "MORE";:INPUT G
|
|
2860 PRINT
|
|
2865 PRINT "29. Warren G. Harding"
|
|
2870 PRINT "Vice President.........Calvin Coolidge"
|
|
2875 PRINT "Party..................Republican"
|
|
2880 PRINT "Term of office.........1921-1923
|
|
2885 PRINT "Wife...................Florence DeWolf"
|
|
2890 PRINT "Senator / Congressman..Yes"
|
|
2895 PRINT "Coinage / Dollar.......None"
|
|
2900 PRINT
|
|
2905 PRINT "30. Calvin Coolidge"
|
|
2910 PRINT "Vice President.........None, Charles G. Dawes"
|
|
2915 PRINT "Party..................Republican"
|
|
2920 PRINT "Term of office.........1923-1929"
|
|
2925 PRINT "Wife...................Grace Goodhue"
|
|
2930 PRINT "Senator / Congressman..No
|
|
2935 PRINT "Coinage / Dollar.......None"
|
|
2940 PRINT
|
|
2945 PRINT "31. Herbert C. Hoover"
|
|
2950 PRINT "Vice President.........Charles Curtis"
|
|
2955 PRINT "Party..................Republican"
|
|
2960 PRINT "Term of office.........1929-1933"
|
|
2965 PRINT "Wife...................Lou Henry"
|
|
2970 PRINT "Senator / Congressman..No"
|
|
2975 PRINT "Coinage / Dollar.......None"
|
|
2980 PRINT "MORE";:INPUT G
|
|
2985 PRINT "32. Franklin Delano Roosevelt"
|
|
2990 PRINT "Vice President.........John N. Garner, Henry A. Wallace, Harry S Truman"
|
|
2995 PRINT "Party..................Democrat"
|
|
3000 PRINT "Term of office.........1933-1945"
|
|
3005 PRINT "Wife...................Elenor Roosevelt"
|
|
3010 PRINT "Senator / Congressman..No"
|
|
3015 PRINT "Coinage / Dollar.......Dime"
|
|
3020 PRINT
|
|
3025 PRINT "33. Harry S Truman"
|
|
3030 PRINT "Vice President.........None, Alben W. Barkley"
|
|
3035 PRINT "Party..................Democrat"
|
|
3040 PRINT "Term of office.........1945-1953"
|
|
3045 PRINT "Wife...................Bess Wallace"
|
|
3050 PRINT "Senator / Congressman..Yes"
|
|
3055 PRINT "Coinage / Dollar.......None"
|
|
3060 PRINT
|
|
3065 PRINT "34. Dwight D. Eisenhower"
|
|
3070 PRINT "Vice President.........Richard M. Nixon"
|
|
3075 PRINT "Party..................Republican"
|
|
3080 PRINT "Term of office.........1953-1961"
|
|
3085 PRINT "Wife...................Mary Geneva Doud"
|
|
3090 PRINT "Senator / Congressman..No"
|
|
3095 PRINT "Coinage / Dollar.......Silver Dollar"
|
|
3100 PRINT "MORE";:INPUT G
|
|
3105 PRINT
|
|
3110 PRINT "35. John F. Kennedy"
|
|
3115 PRINT "Vice President.........Lyndon B. Johnson"
|
|
3120 PRINT "Party..................Democrat"
|
|
3125 PRINT "Term of office.........1961-1963"
|
|
3130 PRINT "Wife...................Jacqueline Bovier"
|
|
3135 PRINT "Senator / Congressman..Yes"
|
|
3140 PRINT "Coinage / Dollar.......Half Dollar"
|
|
3145 PRINT
|
|
3150 PRINT "36.Lyndon B. Johnson"
|
|
3155 PRINT "Vice President.........None, Hubert H. Humphery"
|
|
3160 PRINT "Party..................Democrat"
|
|
3165 PRINT "Term of office.........1963-1969"
|
|
3170 PRINT "Wife...................Claudia Taylor"
|
|
3175 PRINT "Senator / Congressman..Yes"
|
|
3180 PRINT "Coinage / Dollar.......None"
|
|
3185 PRINT
|
|
3190 PRINT "37. Richard M. Nixon"
|
|
3195 PRINT "Vice President.........Spiro T. Agnew, Gerald R. Ford"
|
|
3200 PRINT "Party..................Republican"
|
|
3205 PRINT "Term of office.........1969-1974"
|
|
3210 PRINT "Wife...................Thelma Ryan"
|
|
3215 PRINT "Senator / Congressman..Yes"
|
|
3220 PRINT "Coinage / Dollar.......None"
|
|
3225 PRINT "MORE";:INPUT G
|
|
3230 PRINT
|
|
3235 PRINT "38. Gerald R. Ford"
|
|
3240 PRINT "Vice President.........Nelson A. Rockefeller"
|
|
3245 PRINT "Party..................Republican"
|
|
3250 PRINT "Term of office.........1974-1977"
|
|
3255 PRINT "Wife...................Elizabeth Bloomer"
|
|
3260 PRINT "Senator / Congressman..Yes"
|
|
3265 PRINT "Coinage / Dollar.......None"
|
|
3270 PRINT
|
|
3275 PRINT "39. James E. Carter"
|
|
3280 PRINT "Vice President.........Walter F. Mondale"
|
|
3285 PRINT "Party..................Democrat"
|
|
3290 PRINT "Term of office.........1977-1981"
|
|
3295 PRINT "Wife...................Rosalynn Smith"
|
|
3300 PRINT "Senator / Congressman..No"
|
|
3305 PRINT "Coinage / Dollar.......None"
|
|
3310 PRINT
|
|
3315 PRINT "40. Ronald W. Reagan"
|
|
3320 PRINT "Vice President.........George Bush"
|
|
3325 PRINT "Party..................Republican"
|
|
3330 PRINT "Term of office.........1981-1989"
|
|
3335 PRINT "Wife...................Jane Wyman, Nancy Davis"
|
|
3340 PRINT "Senator / Congressman..No"
|
|
3345 PRINT "Coinage / Dollar.......None"
|
|
3350 PRINT "MORE";:INPUT G
|
|
3355 PRINT
|
|
3360 PRINT "41. George H. W. Bush"
|
|
3365 PRINT "Vice President.........Dan Quail"
|
|
3370 PRINT "Party..................Republican"
|
|
3375 PRINT "Term of office.........1989-"
|
|
3380 PRINT "Wife...................Barbara Pierce"
|
|
3385 PRINT "Senator / Congressman..No"
|
|
3390 PRINT "Coinage / Dollar.......None"
|
|
3395 PRINT "MORE";:INPUT G
|
|
3400 PRINT
|
|
3405 PRINT "Number of presidents per party."
|
|
3410 PRINT "Republican: 17/ Democrat:12 / Democratic-Republican:5"
|
|
3415 PRINT "Whig:4 / Federalist:1 / No Party:1"
|
|
3420 PRINT
|
|
3425 PRINT "Longest term of office: F. D. Roosevelt"
|
|
3430 PRINT "Shortest term of office: William Henry Harrison"
|
|
3435 PRINT "Tallest President: Abraham Lincoln"
|
|
3440 PRINT "Shortest President: James Madison"
|
|
3445 PRINT "Oldest President: Ronald Reagan"
|
|
3450 PRINT "Youngest President to be elected: John F. Kennedy (43)"
|
|
3455 PRINT "Youngest President to take office: Theodore Roosevelt (42)"
|
|
3460 PRINT "Heaviest President: William Howard Taft"
|
|
3465 GOTO 515
|
|
3470 PRINT
|
|
3475 CLS
|
|
3476 PRINT "United States"
|
|
3480 PRINT "View States By..."
|
|
3485 PRINT "1. Capital / Became A State"
|
|
3490 PRINT "2. Entery Into Union"
|
|
3495 PRINT "3. State Abbreviations"
|
|
3500 PRINT "4. U.S. Territories"
|
|
3505 INPUT H
|
|
3510 IF H=1 THEN 3530
|
|
3515 IF H=2 THEN 3815
|
|
3520 IF H=3 THEN 3945
|
|
3525 IF H=4 THEN 4040
|
|
3530 PRINT
|
|
3535 PRINT "NAME CAPITAL BECAME A STATE"
|
|
3540 PRINT "Alabama................Montgomery.................Dec. 14, 1819"
|
|
3545 PRINT "Alaska.................Juneau.....................Jan. 3, 1959"
|
|
3550 PRINT "Arizona................Phoneix....................Feb. 14, 1912"
|
|
3555 PRINT "Arkansas...............Little Rock................June 15, 1863"
|
|
3560 PRINT "California.............Sacramento.................Sept. 9, 1850"
|
|
3565 PRINT "Colorado...............Denver.....................Aug. 1, 1876"
|
|
3570 PRINT "Connecticut............Hartford...................Jan. 9, 1788"
|
|
3575 PRINT "Delaware...............Dover......................Dec. 7, 1787"
|
|
3580 PRINT "Florida................Tallahassee................Mar. 3, 1845"
|
|
3585 PRINT "Georgia................Atlanta....................Jan. 2, 1788"
|
|
3590 PRINT "Hawaii.................Honolulu...................Aug. 21, 1959"
|
|
3595 PRINT "Idaho..................Boise......................July 3, 1890"
|
|
3600 PRINT "Illinois...............Springfield................Dec. 3, 1818"
|
|
3605 PRINT "Indiana................Indianapolis...............Dec. 11, 1816"
|
|
3610 PRINT "Iowa...................Des Moines.................Dec. 28, 1864"
|
|
3615 PRINT "Kansas.................Topeka.....................Jan. 29, 1861"
|
|
3620 PRINT "Kentucky...............Frankfort..................June 1, 1792"
|
|
3625 PRINT "Louisiana..............Baton Rouge................Apr. 30, 1812"
|
|
3630 PRINT "Maine..................Augusta....................Mar. 15, 1820"
|
|
3635 PRINT "Maryland...............Annapolis..................Apr. 28, 1788"
|
|
3640 PRINT "Massachusetts..........Boston.....................Feb. 6, 1788"
|
|
3645 PRINT "MORE";:INPUT F
|
|
3650 PRINT "NAME CAPITAL BECAME A STATE"
|
|
3655 PRINT "Michigan...............Lansing....................Jan. 26, 1837"
|
|
3660 PRINT "Minnesota..............St.Paul....................May 11, 1858"
|
|
3665 PRINT "Mississippi............Jackson....................Dec. 10, 1817"
|
|
3670 PRINT "Missouri...............Jefferson City.............Aug. 10, 1821"
|
|
3675 PRINT "Montana................Helena.....................Nov. 8, 1889"
|
|
3680 PRINT "Nebraska...............Lincoln....................Mar. 1, 1867"
|
|
3685 PRINT "Nevada.................Carson City................Oct. 31, 1864"
|
|
3690 PRINT "New Hampshire..........Concord....................June 21, 1788"
|
|
3695 PRINT "New Jersey.............Trenton....................Dec. 18, 1887"
|
|
3700 PRINT "New Mexico.............Santa Fe...................Jan. 6, 1912"
|
|
3705 PRINT "New York...............Albany.....................July 26, 1788"
|
|
3710 PRINT "North Carolina.........Raleigh....................Nov. 21, 1789"
|
|
3715 PRINT "North Dakota...........Bismark....................Nov. 2, 1889"
|
|
3720 PRINT "Ohio...................Columbus...................Mar. 1, 1803"
|
|
3725 PRINT "Oklahoma...............Oklahoma City..............Nov. 16, 1907"
|
|
3730 PRINT "Oregon.................Salem......................Feb. 14, 1859"
|
|
3735 PRINT "Pennsylvania...........Harrisburg.................Dec. 12, 1857"
|
|
3740 PRINT "Rhode Island...........Providence.................May 29, 1790"
|
|
3745 PRINT "South Carolina.........Columbia...................May 23, 1788"
|
|
3750 PRINT "South Dakota...........Pierre.....................Nov. 2, 1889"
|
|
3755 PRINT "Tennessee..............Nashville..................June 1, 1796"
|
|
3760 PRINT "Texas..................Austin.....................Dec. 29, 1845"
|
|
3770 PRINT "MORE";:INPUT F
|
|
3775 PRINT "NAME CAPITAL BECAME A STATE"
|
|
3777 PRINT "Utah...................Salt Lake City.............Jan. 4, 1896"
|
|
3780 PRINT "Vermont................Montpelier.................Mar. 4, 1791"
|
|
3785 PRINT "Virginia...............Richmond...................June 25, 1788"
|
|
3790 PRINT "Washington.............Olympia....................Nov. 11, 1889"
|
|
3795 PRINT "West Virginia..........Charleston.................June 20, 1863"
|
|
3800 PRINT "Wisconson..............Madison....................May 29, 1848"
|
|
3805 PRINT "Wyoming................Cheynne....................July 10, 1890"
|
|
3810 GOTO 515
|
|
3815 PRINT
|
|
3820 PRINT "1. Delaware 26. Michigan"
|
|
3825 PRINT "2. Pennsylvania 27. Florida"
|
|
3830 PRINT "3. New Jersey 28. Texas"
|
|
3835 PRINT "4. Georgia 29. Iowa"
|
|
3840 PRINT "5. Connecticut 30. Wisconson"
|
|
3845 PRINT "6. Massachusetts 31. California"
|
|
3850 PRINT "7. Maryland 32. Minnesota"
|
|
3855 PRINT "8. South Carolina 33. Oregon"
|
|
3860 PRINT "9. New Hampshire 34. Kansas"
|
|
3865 PRINT "10. Virginia 35. West Virginia"
|
|
3870 PRINT "11. New York 36. Nevada"
|
|
3875 PRINT "12. North Carolina 37. Nebraska"
|
|
3880 PRINT "13. Rhode Island 39. North Dakota"
|
|
3885 PRINT "14. Vermont 40. South Dakota"
|
|
3890 PRINT "15. Kentucky 41. Montana"
|
|
3895 PRINT "16. Tennessee 42. Washington"
|
|
3900 PRINT "17. Ohio 43. Idaho"
|
|
3905 PRINT "18. Louisiana 44. Wyoming"
|
|
3910 PRINT "19. Indiana 45. Utah"
|
|
3915 PRINT "20. Mississippi 46. Oklahoma"
|
|
3920 PRINT "21. Illinois 47. New Mexico"
|
|
3925 PRINT "22. Alabama 48. Arizona"
|
|
3930 PRINT "23. Maine 49. Alaska"
|
|
3935 PRINT "24. Missouri 25. Arkansas 50. Hawaii ";
|
|
3940 GOTO 515
|
|
3945 CLS
|
|
3950 PRINT "Alabama-------AL Alaska-------AK Arizona-------AZ"
|
|
3955 PRINT "Arkansas------AR California---CA Colorado------CO"
|
|
3960 PRINT "Connecticut---CT Delaware-----DE Florida-------FL"
|
|
3965 PRINT "Georgia-------GA Hawaii-------HI Idaho---------ID"
|
|
3970 PRINT "Illinois------IL Indiana------IN Iowa----------IA"
|
|
3975 PRINT "Kansas--------KS Kentucky-----KY Louisiana-----LA"
|
|
3980 PRINT "Maine---------ME Maryland-----MD Massachusetts-MA"
|
|
3985 PRINT "Michigan------MI Minnesota----MN Mississippi---MS"
|
|
3990 PRINT "Missouri------MO Montana------MT Nebraska------NE"
|
|
3995 PRINT "Nevada--------NV New Hampshire-NH New Jersey----NJ"
|
|
4000 PRINT "New Mexico----NM New York-----NY North Carolina-NC"
|
|
4005 PRINT "North Dakota--ND Ohio---------OH Oklahoma------OK"
|
|
4010 PRINT "Oregon--------OR Pennsylvania-PA Rhode Island--RI"
|
|
4015 PRINT "South Carolina-SC South Dakota-SD Tennessee-----TN"
|
|
4020 PRINT "Texas---------TX Utah---------UT Vermont-------VT"
|
|
4025 PRINT "Virginia------VA Washington---WA West Virginia-WV"
|
|
4030 PRINT "Wisconson-----WI Wyoming------WY"
|
|
4035 GOTO 515
|
|
4040 PRINT "American Samoa, Guam, Midway Island, Northern Marina Island"
|
|
4045 PRINT "Panama Canal Zone, Puerto Rico, Virgin Islands, Wake Island"
|
|
4050 GOTO 515
|
|
4055 CLS
|
|
4056 PRINT
|
|
4057 PRINT
|
|
4058 PRINT
|
|
4059 PRINT
|
|
4060 PRINT " ***************************************"
|
|
4065 PRINT " * *"
|
|
4070 PRINT " * PROGRAMMER: Scott Sexton *"
|
|
4075 PRINT " * *"
|
|
4085 PRINT " * *"
|
|
4090 PRINT " * PRESIDENTS: Andy Alderman *"
|
|
4095 PRINT " * World Almanac (1982) *"
|
|
4100 PRINT " * *"
|
|
4105 PRINT " * SOLAR SYSTEM: Funk & Wagnall's *"
|
|
4110 PRINT " * encyclopedia (1975) *"
|
|
4115 PRINT " * *"
|
|
4120 PRINT " * *"
|
|
4125 PRINT " * *"
|
|
4130 PRINT " * Copyright 1990 Scott Sexton *"
|
|
4145 PRINT " * *"
|
|
4150 PRINT " ***************************************"
|
|
4155 PRINT
|
|
4160 PRINT "QUIT / MCP (Q/M)";:INPUT H$
|
|
4165 IF H$= "M" THEN 4170 ELSE SYSTEM
|
|
4170 CLS
|
|
4175 RUN"MCP"
|
|
|
|
##########
|
|
## [02] ##
|
|
###########################################################################
|
|
## FILENAME: "caitlin.pl"
|
|
## LANGUAGE: PERL
|
|
## AUTHOR: Jamesy
|
|
###########################################################################
|
|
|
|
#!/usr/bin/perl
|
|
# caitlin.pl - A script that randomly picks out one of the
|
|
# many annoying traits of hers and outputs an email of
|
|
# how annoying it is, and how annoying she is.
|
|
|
|
# Last modified 5/10/99 by James Hetfield
|
|
|
|
# define local variables here
|
|
|
|
$mail_prog = "/usr/lib/sendmail -t"; # Location of mailer
|
|
$caitlin_email = 'Synikalle@members.xoom.com'; # Caitlin's current
|
|
# Email Address
|
|
|
|
$program_email = 'IH8CAITLIN@Aol.com'; # Program's Email Address
|
|
|
|
# Here is the Caitlin hash. This associate array contains
|
|
# keys related to her annoying traits, and values relating to
|
|
# the output the email will have about her annoying trait.
|
|
|
|
%CAITLIN = (
|
|
"too_thin" = "WHO DO YOU THINK YOU ARE, KATE MOSS?";
|
|
"dislikes" = "YOU DISLIKE MEAN PEOPLE. YOU SUCK.";
|
|
"computers" = "ON YOUR WEBPAGE YOU SAY YOU DISLIKE COMPUTERS. YOU'RE AN IDIOT.";
|
|
"prejuidism" = "ON YOUR WEBPAGE YOU SAY YOU DISLIKE PREJUIDISM. WHAT THE FUCK IS THAT? CAN'T YOU SPELL?";
|
|
"internet" = "ON YOUR WEBPAGE YOU SAY YOU DISLIKE THE INTERNET. YOU THINK YOU'RE SO FUNNY, DON'T YOU?";
|
|
"tv" = "TV SUCKS, AND SO DO YOU.";
|
|
"korn" = "KORN SUCKS. YOU SUCK. DIE.";
|
|
"styx" = "I GUESS YOU DON'T KNOW WHAT A GENERATION GAP IS, DO YOU?";
|
|
"worship" = "YOU HAVE WORSHIP WEB PAGES. THEY'RE ON XOOM. YOU'RE DUMB.";
|
|
"yanno" = "YOU SAY THINGS LIKE 'yanno?'. DIE.";
|
|
"16" = "YOU'RE SIXTEEN. SHUT UP.";
|
|
"lol" = "YOU PUT LOL ON YOUR WEBPAGE. YOU SUCK.";
|
|
"hair" = "YOU'RE ONLY 16 AND YOU'VE ALREADY FUCKED UP YOUR HAIR FOR LIFE WITH ALL THOSE FUCKING DYES. CONGRATS!";
|
|
"clothes" = "YOUR MOTHER SURE DRESSES YOU FUNNY.";
|
|
"dumb" = "UHHH YOU'RE DUMB.";
|
|
);
|
|
|
|
# Now that we have the associate array defined, we'll have an array
|
|
# of keynames so we can easily do a random function on the keys.
|
|
|
|
@caitlin = ("too_thin", "dislikes", "computers", "prejuidism", "internet",
|
|
"tv", "korn", "styx", "worship", "yanno", "16", "lol", "hair", "clothes",
|
|
"dumb");
|
|
|
|
# get a pseudo-random seed
|
|
|
|
srand(time ^ $$);
|
|
|
|
# pick out a random insult
|
|
|
|
$insult_key = $caitlin[rand(@caitlin)];
|
|
$insult = $CAITLIN{"$insult_key"};
|
|
|
|
# Now that we have an insult, send her the email!
|
|
|
|
open(MAIL, "|$mail_prog") || die "Couldn't open mailer: $!\n";
|
|
print MAIL <<END;
|
|
From: $program_email
|
|
To: $caitlin_email
|
|
Subject: Caitlin.pl Auto-Generated Mailing
|
|
|
|
GOD, CAITLIN, WHY DO YOU SUCK SO MUCH?
|
|
|
|
$insult
|
|
|
|
YOU SURE ARE DUMB.
|
|
|
|
END
|
|
close(MAIL);
|
|
|
|
##########
|
|
## [03] ##
|
|
###########################################################################
|
|
## FILENAME: "Simple Command Line File Copy Program"
|
|
## LANGUAGE: C
|
|
## AUTHOR: AltRocks
|
|
## COMMENTS: I made a nice simple little program in C. It's basically a
|
|
## cheap hack of the DOS command line copy, but it's made for
|
|
## linux. :)
|
|
###########################################################################
|
|
|
|
/* Jeff Witman */
|
|
/* Simple command line file copy program */
|
|
|
|
#include <stdio.h>
|
|
|
|
main(int argc, char *argv[])
|
|
{
|
|
|
|
FILE *OldFile, *NewFile;
|
|
int c;
|
|
|
|
|
|
if (argc < 3)
|
|
{
|
|
fprintf(stderr, "Not Enough Arguments.\n");
|
|
fprintf(stderr, "mycopy.e <oldfile.name> <newfile.name>\n");
|
|
exit(1);
|
|
}
|
|
|
|
if (argc > 3)
|
|
{
|
|
fprintf(stderr, "Too many arguments.\n");
|
|
fprintf(stderr, "mycopy.e <oldfile.name> <newfile.name>\n");
|
|
exit(1);
|
|
}
|
|
|
|
if ((OldFile=fopen(argv[1], "rb"))==NULL)
|
|
{
|
|
fcloseall();
|
|
fprintf(stderr, "Error Opening Source File.\n");
|
|
fprintf(stderr, "Make Sure File Exists, Or Is Not Write Protected.\n");
|
|
exit(1);
|
|
}
|
|
|
|
if ((NewFile=fopen(argv[2], "wb"))==NULL)
|
|
{
|
|
fcloseall();
|
|
fprintf(stderr, "Error Opening Destination File.\n");
|
|
fprintf(stderr, "Make Sure Disk Drive Exists, The Disk Is Inserted Properly, Or Is Not Write Protected.");
|
|
exit(1);
|
|
}
|
|
|
|
|
|
while(1)
|
|
{
|
|
|
|
c=fgetc(OldFile);
|
|
|
|
if (!feof(OldFile))
|
|
fputc(c, NewFile);
|
|
else
|
|
break;
|
|
|
|
}
|
|
|
|
puts("Success !");
|
|
|
|
fcloseall();
|
|
|
|
}
|
|
|
|
##########
|
|
## [04] ##
|
|
###########################################################################
|
|
## FILENAME: "Hangman Fun"
|
|
## LANGUAGE: Java
|
|
## AUTHOR: Cyn
|
|
###########################################################################
|
|
|
|
//This is a game I made for my CS class a while ago. It's actually hard
|
|
//as hell to beat, but you can look up the words since they're in the code.
|
|
//Have fun.
|
|
//Oh, and you should save it as Game.java and compile it using the jdk1.1.x
|
|
//It uses some deprecated API, but I compiled it under 1.1.6, and it
|
|
//wasn't a problem.
|
|
|
|
import java.awt.*;
|
|
import java.awt.event.*;
|
|
/** Game creates a frame containing
|
|
a Hangmanpanel,
|
|
a HangmanTextField,
|
|
a HangmanCanvas,
|
|
and a reset button */
|
|
class Game extends Frame {
|
|
HangmanCanvas c;//declares HangManConvas c
|
|
HangmanTextField t;//declares HangmanTextField t
|
|
HangmanPanel p;//declares HangmanPanel p
|
|
Game() {
|
|
addWindowListener(new WindowAdapter() {
|
|
public void windowClosing(WindowEvent e) {
|
|
System.exit(0);//adds WindowListener to Game to close frame
|
|
}
|
|
});
|
|
//{{INIT_CONTROLS
|
|
setLayout(new BorderLayout(0,0));
|
|
setVisible(false);
|
|
setSize(insets().left + insets().right + 500,insets().top + insets().bottom + 500);
|
|
setTitle("Untitled");
|
|
//}}
|
|
//{{INIT_MENUS
|
|
//}}//visual cafe code to set border layout, and set size to height and width 500
|
|
//setSize(500,500);
|
|
//setLayout(new BorderLayout());
|
|
c = new HangmanCanvas();//creates new HangmanCanvas c
|
|
t = new HangmanTextField(c,p);//creates new HangmanTextField t
|
|
p = new HangmanPanel(t);//creates new HangmanPanel p
|
|
add("North",t);//adds HangmanTextField to the North of frame
|
|
add("Center",c);//adds HangmanCanvas to the Center of frameays Reset
|
|
add("South",p);//adds HangmanPanel to South of frame
|
|
Button reset = new Button("Reset");//adds ActionListener to Button Reset
|
|
reset.addActionListener(new ActionListener() {
|
|
public void actionPerformed(ActionEvent e) {
|
|
c.resetWrongGuesses();
|
|
t.reset();
|
|
p.reset();
|
|
}//has Button reset the number of wrong guesses, HangmanTextField, and HangmanPanel
|
|
});
|
|
add("East",reset);//adds reset button to east
|
|
}
|
|
public static void main (String[] args) {
|
|
Game f = new Game();//creates new Game f
|
|
f.show();
|
|
}
|
|
}
|
|
|
|
class HangmanCanvas extends Canvas {//creates class HangmanCanvas, extends Canvas
|
|
private int wrongGuesses = 0;//declares private int wrongGuesses, sets it to 0
|
|
public void resetWrongGuesses() {//creates resetWrongGuesses() method
|
|
wrongGuesses = 0;//has resetWrongGuesses method set wrongGuesses to 0
|
|
repaint();//has resetWrongGuesses repaint the canvas
|
|
}
|
|
public void addWrongGuess() {//creates addWrongGuess method
|
|
wrongGuesses++;//has addWrongGuess add one to wrongGuesses
|
|
repaint();//has addWrongGuess repaint the canvas
|
|
}
|
|
|
|
public int checkWrongGuess(){//creates checkWrongGuess method
|
|
return wrongGuesses;//returns number of wrongGuesses
|
|
}
|
|
|
|
public void paint(Graphics g) {
|
|
g.setColor(Color.black);//makes scaffold black
|
|
g.fillRect(0,220,200,5); // base of scaffold
|
|
g.fillRect(0,0,70,5); // top of scaffold
|
|
g.fillRect(0,0,5,220); // side of scaffold
|
|
switch (wrongGuesses) {
|
|
case 7: g.fillRect(45,5,5,15); // rope
|
|
g.setColor(Color.red);//colors mouth red
|
|
g.fillArc(35,50,20,20,10,170); // exMouth
|
|
case 6: g.setColor(Color.blue);//colors leg blue
|
|
g.drawLine(45,140,70,200);// right leg
|
|
case 5: g.setColor(Color.blue);//colors leg blue
|
|
g.drawLine(45,140,20,200);// left leg
|
|
case 4: g.setColor(Color.orange);//colors arm orange
|
|
g.drawLine(45,85,80,65); // right arm
|
|
case 3: g.setColor(Color.orange);//colors arm orange
|
|
g.drawLine(45,85,10,65); // left arm
|
|
case 2: g.setColor(Color.orange);//colors body orange
|
|
g.drawLine(45,70,45,140); // body
|
|
case 1: g.setColor(Color.black);//colors face black
|
|
if (wrongGuesses < 7) g.fillArc(35,40,20,20,-10,-170); // mouth
|
|
g.drawOval(20,20,50,50); // head
|
|
g.setColor(Color.green);//colors eyes green
|
|
g.fillOval(30,40,7,7); // left eye
|
|
g.fillOval(50,40,7,7); // right eye
|
|
}
|
|
}
|
|
}
|
|
|
|
class HangmanPanel extends Panel {
|
|
Button b[] = new Button[26];//creates an array of 26 buttons
|
|
int i;//declares int i
|
|
HangmanTextField textField;//declares HangmanTextField textField
|
|
String alphabet = "abcdefghijklmnopqrstuvwxyz";
|
|
|
|
|
|
HangmanPanel(HangmanTextField t) {
|
|
textField = t;
|
|
setSize(300,100);//gives HangmanPanel height 300 and width 100
|
|
setLayout(new GridLayout(2,13));//sets GridLayout of 2 by 13
|
|
for (i = 0; i < 26; i++) {
|
|
b[i] = new Button(alphabet.substring(i,i+1));
|
|
b[i].setBackground(Color.red);
|
|
b[i].addActionListener(new ActionListener() {
|
|
Button mybutton = b[i];
|
|
char mychar = alphabet.charAt(i);
|
|
// all this creates red buttons labeled with the letters of the alphabet
|
|
public void actionPerformed(ActionEvent e) {
|
|
textField.getGuess(mychar);//performs getGuess method
|
|
mybutton.setBackground(Color.blue);//makes button blue when clicked
|
|
if (test == true){
|
|
mybutton.removeActionListener(this);
|
|
}
|
|
}
|
|
});
|
|
add(b[i]);
|
|
}
|
|
}
|
|
|
|
public boolean test;
|
|
|
|
public void reset() {
|
|
for (int i = 0; i<26; i++) {
|
|
b[i].setBackground(Color.red);//has reset method turn buttons red
|
|
}
|
|
}
|
|
}
|
|
|
|
class HangmanTextField extends java.awt.TextField {
|
|
String toBeGuessed = "enter your text here";//creates String toBeGuessed
|
|
StringBuffer displayString=new StringBuffer(toBeGuessed);//creates StringBuffer to display String toBeGuessed
|
|
HangmanCanvas canvas;//declares HangmanCanvas canvas
|
|
HangmanPanel panel;
|
|
HangmanTextField(HangmanCanvas c, HangmanPanel p) {
|
|
canvas = c;
|
|
panel = p;
|
|
|
|
|
|
toBeGuessed = word();
|
|
toBeGuessed.toLowerCase();//makes toBeGuessed lower case
|
|
displayString = new StringBuffer(toBeGuessed);//creates displayString, a new StringBuffer containing the strong toBeGuessed
|
|
/* Convert all non-space characters to - */
|
|
for (int i=0; i<displayString.length(); i++) {
|
|
if (displayString.charAt(i) != ' ') displayString.setCharAt(i,'-');
|
|
}
|
|
setText(displayString.toString());
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void getGuess(char c) {
|
|
int hits = 0;
|
|
/* replace the - corresponding to any occurrences of c by c */
|
|
for (int i=0; i<displayString.length(); i++) {
|
|
if (toBeGuessed.charAt(i) == c) {
|
|
displayString.setCharAt(i,c);
|
|
hits++;
|
|
}
|
|
}
|
|
if (canvas.checkWrongGuess() >= 6){
|
|
setText("Ha ha. You Lost.");//has textField display losing message if there are more than seven wrong guesses
|
|
}
|
|
if (toBeGuessed.equals(displayString.toString()) == true) {
|
|
setText("Congratulations! You Have Won!");//displays win message if there are no - in display string
|
|
}
|
|
/* if any replacements occurred, update the display string */
|
|
if (hits > 0){
|
|
setText(displayString.toString());
|
|
}
|
|
/* otherwise inform the canvas of another wrong guess */
|
|
else {
|
|
if (toBeGuessed.equals(displayString.toString()) != true) //doesn't add wrong guesses if you've already won
|
|
canvas.addWrongGuess(); }
|
|
|
|
}
|
|
|
|
|
|
void reset() {
|
|
toBeGuessed = word();
|
|
displayString = new StringBuffer(toBeGuessed);
|
|
toBeGuessed.toLowerCase();//makes toBeGuessed lower case
|
|
displayString = new StringBuffer(toBeGuessed);//creates displayString, a new StringBuffer containing the strong toBeGuessed
|
|
/* Convert all non-space characters to - */
|
|
for (int i=0; i<displayString.length(); i++) {
|
|
if (displayString.charAt(i) != ' ') displayString.setCharAt(i,'-');
|
|
}
|
|
setText(displayString.toString());
|
|
}
|
|
|
|
|
|
|
|
public String word() {
|
|
|
|
String[] words;
|
|
words = new String[10];
|
|
|
|
words[0] = "hubris";
|
|
words[1] = "avuncular";
|
|
words[2] = "baklava";
|
|
words[3] = "agape";
|
|
words[4] = "horrid";
|
|
words[5] = "tragic";
|
|
words[6] = "primer";
|
|
words[7] = "elegant";
|
|
words[8] = "nice";
|
|
words[9] = "machine";
|
|
|
|
int a = (int)(Math.random()*10);
|
|
|
|
return words[a];
|
|
}
|
|
|
|
}
|
|
|
|
##########
|
|
## [05] ##
|
|
###########################################################################
|
|
## FILENAME: "makegore.c"
|
|
## LANGUAGE: C
|
|
## AUTHOR: gd & zab
|
|
###########################################################################
|
|
|
|
/*
|
|
|
|
makegore.c
|
|
|
|
version 0.3.0
|
|
|
|
this program generates a file named 'gore' which will be a size in
|
|
megabytes as specified by the user.
|
|
|
|
by the dennis courtney 5ive
|
|
|
|
email: djc@uclink4.berkeley.edu
|
|
|
|
*/
|
|
|
|
#include <stdio.h>
|
|
|
|
#define _G "_GORE"
|
|
|
|
static char gorestr[]= _G _G _G _G _G _G _G _G _G _G _G _G _G _G _G _G _G _G;
|
|
|
|
int main()
|
|
{
|
|
int outfd,left;
|
|
|
|
printf("makegore.\n\n");
|
|
printf("how many megs of _gore: ");
|
|
scanf("%d", &left);
|
|
|
|
left*=(1024*1024);
|
|
printf("\n");
|
|
|
|
if((outfd=creat("gore",0644)) <0 ) {
|
|
printf("can not open file \"gore\". system took you.\n");
|
|
exit(1);
|
|
}
|
|
while(left>(sizeof(gorestr))-1) {
|
|
left-=write(outfd,gorestr,(sizeof(gorestr))-1);
|
|
}
|
|
|
|
write(outfd,gorestr,left);
|
|
close(outfd);
|
|
return 0;
|
|
}
|
|
|
|
##########
|
|
## [06] ##
|
|
###########################################################################
|
|
## FILENAME: "Tic-Tac-Toe, One In A Row"
|
|
## LANGUAGE: C
|
|
## AUTHOR: Ior
|
|
###########################################################################
|
|
|
|
/* "tic-tac-toe, one in a row"
|
|
a dc5 ultramedia game
|
|
by ior
|
|
*/
|
|
|
|
#include <stdio.h>
|
|
|
|
/* prototype */
|
|
|
|
void tic ();
|
|
|
|
|
|
/* rice, noodles, fun */
|
|
|
|
int main () {
|
|
|
|
char blah;
|
|
|
|
printf("\ni be dc5. irie.\n");
|
|
printf("\n");
|
|
printf("welcome to tic-tac-toe, one in a row.\n");
|
|
printf("i have been programmed with the most eliten advanced ai logics to date.\n");
|
|
printf("so i will go first.\n");
|
|
|
|
do {
|
|
|
|
tic();
|
|
|
|
printf("\nlet's play again, shall we? ");
|
|
blah = getchar();
|
|
printf("\nwinner goes first.\n");
|
|
|
|
} while (1 == 1);
|
|
|
|
}
|
|
|
|
|
|
void tic () {
|
|
|
|
printf("\nnew game: \n");
|
|
|
|
printf(" _ \n");
|
|
printf("| |\n");
|
|
printf(" - \n");
|
|
|
|
printf("\nmy move: \n");
|
|
|
|
printf(" _ \n");
|
|
printf("|X|\n");
|
|
printf(" - \n");
|
|
|
|
}
|
|
|
|
##########
|
|
## [07] ##
|
|
###########################################################################
|
|
## FILENAME: "dsp.s"
|
|
## LANGUAGE: HC11 Assembler
|
|
## AUTHOR: Ior
|
|
###########################################################################
|
|
|
|
.processor m68hc11
|
|
|
|
;-- dsp.s
|
|
|
|
;-- ugly assembler code for a motorola hc11 processor
|
|
;--
|
|
;-- the very start of it just initializes the segments and sets up regsiters
|
|
;-- for rs232 baud rate, etc.
|
|
;--
|
|
;-- the rest of it is a little more interesting. it checks all the ram
|
|
;-- on the board (well, the board that this was used in) by doing
|
|
;-- walking ones (with logical shift left) through each register.
|
|
;--
|
|
;-- then it gets fun. the board that this chip was running was a
|
|
;-- custom dsp with an adjustable feedback and adjustable delay
|
|
;-- (think of it as a guitar pedal). the chip has 4 embedded
|
|
;-- adcs, the first is used for the audio input, the second for the
|
|
;-- delay, and the third for the feedback. the last is unused.
|
|
;--
|
|
;-- the trickiest part involved the sampling. the board only had
|
|
;-- 8k of ram, and i wanted to use all of it as a sample buffer
|
|
;-- to have the longest possible delays i could. this meant
|
|
;-- doing all memory 'pointer' and data manipulations through
|
|
;-- registers. the hc11 only has 4 registers. two 16 bit registers
|
|
;-- (X and Y) inteded to be used solely for memory addresses
|
|
;-- and two 8 bit registers (A and B) inteded as accumulators.
|
|
;-- registers A and B can be combined into a double accumulator
|
|
;-- D. this means there are only three 16 bit registers on the chip.
|
|
;-- to make things even more difficult, the hc11 engineers decided
|
|
;-- there would be absolutely no use for a 'mov' opcode. dumb.
|
|
|
|
;-- startup runtime code
|
|
;-- basic test code for board verification
|
|
;--
|
|
.external _main, __memory, _memerror, _showmem, _curraddr, _MemoryValid, _WR
|
|
.external _temp, _feedback
|
|
.public __stext, _dac_init, _adc_init
|
|
|
|
;-- get segment boundaries found in the *.lnk file and assign them to labels
|
|
|
|
.psect _bss
|
|
__sbss: ;-- label to base of bss segment (static, uninit. data)
|
|
|
|
.psect _data
|
|
__sdata: ;-- label base of data segment (init. data)
|
|
|
|
|
|
;get the code segment beginning from the *.lnk file and locate asm code there
|
|
;
|
|
.psect _text
|
|
__stext: ;-- label to base of text segment (code in rom)
|
|
clrb ;-- b=0
|
|
ldy #0 ;-- y=0
|
|
|
|
;setup monitor stack frame at the top of zpage inside the hc11
|
|
prog:
|
|
ldx #0ffh ;-- x <- ffh
|
|
txs ;-- sp <- x
|
|
|
|
;-- Initialize SCI
|
|
ldab #48 ;-- BAUD = 0x30
|
|
ldy #4096
|
|
stab 43, y
|
|
|
|
ldab #44 ;-- SCCR2 = 0x2c
|
|
stab 45, y
|
|
|
|
;-- Initialize Real Time Interrupt
|
|
bset 3, 38, y ;-- PACTL |= 0x03
|
|
bset 64, 36, y ;-- TMSK2 |= RTII;
|
|
|
|
;-- initialize adc
|
|
bset 128, 57, y ;-- OPTION |= 0x80
|
|
bset 48, 48, y ;-- ADCTL |= 0x30
|
|
|
|
;-- Start Checking memory
|
|
memcheck:
|
|
ldaa #1 ;-- Set Memory Valid Flag to 1 for Valid
|
|
staa _MemoryValid
|
|
ldx #6000h ;-- Start at memory location 6000h
|
|
|
|
; jmp _main ;-- remove this for memcheck
|
|
|
|
addr_lp:
|
|
ldaa #1 ;-- Start with ACCA = 1
|
|
|
|
byte_lp:
|
|
staa 0, x ;-- Save ACCA at current memory address in X
|
|
ldab 0, x ;-- Load ACCB from current memory address in X
|
|
cba ;-- compare ACCA and ACCB
|
|
bne bad ;-- If Not equal then memory location is bad
|
|
lsla ;-- Rotate ACCA Left for Next Value
|
|
bne byte_lp ;-- Loop until ACCA is 0 again
|
|
|
|
stx _curraddr ;-- Show current mem address
|
|
jsr _showmem
|
|
|
|
next_addr:
|
|
inx ;-- Move X to next address
|
|
cpx #8000h ;-- Check if end of memeory otherwise check next address
|
|
bne addr_lp
|
|
jmp done ;-- done checking mem, go to main
|
|
|
|
bad:
|
|
clr _MemoryValid ;-- Set Memory Valid Flag to 0 for Invalid
|
|
|
|
stx _curraddr ;-- Show current bad memory address
|
|
jsr _memerror
|
|
jmp next_addr ;-- Test next address
|
|
|
|
|
|
_dac_init:
|
|
ldaa #0 ;-- initialize digital out to 00
|
|
ldx #2000h ;-- start at memory location 2000h
|
|
dac_loop:
|
|
staa 0, x ;-- write ACCA to memory in REGX
|
|
cmpa #255 ;-- if digital out is 0xFF
|
|
beq _dac_init ;-- reset!
|
|
|
|
inca ;-- increment ACCA
|
|
jmp dac_loop ;-- or keep incrementing
|
|
|
|
;-- for analog->digital conversion
|
|
;-- REGX is always the head (write) pointer for circular queue
|
|
;-- REGY is always the tail (read) pointer for circular queue
|
|
;-- to avoid possible overwriting problems, use ACCA to read from ADRx
|
|
;-- and write to RAM
|
|
;-- and use ACCB to read from RAM and write to 0x2000 (memory mapped DAC)
|
|
|
|
;-- ADC initialization
|
|
_adc_init:
|
|
ldx #6000h ;-- head pointer (WR)
|
|
ldy #6000h ;-- tail pointer (RD)
|
|
|
|
;-- READ ADC loop
|
|
adc_loop:
|
|
|
|
|
|
;-- FEEDBACK DELAY
|
|
feedback_delay:
|
|
ldab 1033h ;-- ACCB = ADR2 at 0x1032
|
|
ldaa 0, y ;-- ACCA = oldoutput
|
|
negb ;-- offset = -offset
|
|
feedback_offset: ;-- do {
|
|
lsra ;-- oldoutput / 2
|
|
lsrb ;-- offset / 2
|
|
bne feedback_offset ;-- } while (offset != 0)
|
|
offset_done:
|
|
tab ;-- ACCB = ACCA
|
|
ldaa 1031h ;-- ACCA = ADR1 at 0x1031
|
|
aba ;-- ACCA = ACCA + ACCB
|
|
staa 0, x ;-- write to WR pointer
|
|
|
|
;-- calculate ECHO offset
|
|
echo_offset:
|
|
stx _WR
|
|
ldab 1032h ;-- ACCB = ADR2 at 0x1032
|
|
lsrb ;-- ACCB = ACCB / 16
|
|
lsrb
|
|
lsrb
|
|
lsrb
|
|
negb ;-- ACCB = -ACCB
|
|
ldy _WR
|
|
aby ;-- REGY = REGY + (-ACCB)
|
|
cpy #6000h ;-- compare to start of RAM
|
|
sty _WR
|
|
blt back_wrap ;-- if under start, take care of it!
|
|
end_wrap:
|
|
ldy _WR
|
|
|
|
;-- WRITE DAC loop
|
|
ldab 0, y ;-- read from RD pointer
|
|
iny ;-- REGY++
|
|
cpy #8000h ;-- RD at end of RAM?
|
|
beq tail_reset ;-- then restart at start of circular queue
|
|
|
|
return_tail:
|
|
ldaa 0, x ;-- read from WR pointer (current input)
|
|
inx
|
|
cpx #8000h ;-- WR at end of RAM?
|
|
beq head_reset ;-- then restart at start of circular queue
|
|
return_head:
|
|
aba ;-- ACCA = ACCA + ACCB (both samples)
|
|
staa 2000h ;-- write sample to DAC
|
|
jmp adc_loop ;-- loop!
|
|
|
|
|
|
head_reset:
|
|
ldx #6000h ;-- reset WR pointer to top of RAM
|
|
jmp return_head
|
|
|
|
tail_reset:
|
|
ldy #6000h ;-- reset RD pointer to top of RAM
|
|
jmp return_tail
|
|
|
|
|
|
;-- when 'echoing' the RD pointer, if it gets moved under the start of RAM
|
|
;-- then this will wrap it to the end
|
|
back_wrap:
|
|
ldd #6000h ;-- start of RAM
|
|
subd _WR ;-- ACCD = 0x6000 - REGY
|
|
std _temp ;-- _temp = ACCD
|
|
bgt wrap
|
|
jmp end_wrap
|
|
|
|
wrap:
|
|
ldd #8000h ;-- ACCD = end of RAM
|
|
subd _temp ;-- ACCD = ACCD - _WR
|
|
std _WR
|
|
jmp end_wrap
|
|
|
|
|
|
|
|
done:
|
|
jmp _main ;-- execute main
|
|
.end
|
|
|
|
##########
|
|
## [08] ##
|
|
###########################################################################
|
|
## FILENAME: "poe.pl"
|
|
## LANGUAGE: PERL
|
|
## AUTHOR: AIDS
|
|
###########################################################################
|
|
|
|
#!/usr/bin/perl
|
|
## poe.pl [by AIDS]
|
|
## WOW THIS STUFF DOES SOME FUN STUFF IT MAKES A SOURCE OF WORD RELATIONSHIP
|
|
## FILES. YOU CAN USE THIS TO EMULATE NATURAL LANGUAGE PATTERNS.
|
|
## THERE WAS ANOTHER FILE WHICH DID THIS AUTOMATICALLY, BUT I LOST THE CODE.
|
|
## THIS CODE IS COOL THOUGH.
|
|
## BECAUSE IT'S INNEFFICIENT AND STUPID.
|
|
## AND IT GOT ME AN A iN CREATIVE WRITING.
|
|
## UH BASICALLY
|
|
## EVERYTIME A WORD APPEARS AFTER ANOTHER WORD
|
|
## IT GOES TO A FILE OF THE SAME NAME AS THE WORD
|
|
## AND PUTS THE WORD THAT COMES AFTER IT IN THAT FILE
|
|
## ALONG WITH A NUMBER
|
|
## THE NUMBER BEING HTE AMOUNT OF TIMES THAT THE WORDS HAVE APPEARED ON
|
|
## CONJUNCTION
|
|
## THIS METHOD WORKS SURPRISINGLY WELL
|
|
## IF I WERE TO REWRITE THIS TODAY
|
|
## I WOULD DO IT WITH GIGNATIC HASH TABLES
|
|
## UH
|
|
## ENJOY
|
|
|
|
open (FUXOR, $ARGV[0]) or die print "A horrible death\n";
|
|
|
|
while ($line = <FUXOR>){
|
|
|
|
@line2 = (@line2, split(" ",$line))}
|
|
|
|
open (STARTFILE, ">>words/#STARTUP#");
|
|
$hurtmebad=$line2[0];
|
|
$hurtmebad=~s/\W//g;
|
|
print STARTFILE $hurtmebad, "\n";
|
|
close(STARTFILE);
|
|
|
|
for ($b=0; $b<scalar(@line2); $b++){
|
|
unless ($b == (scalar(@line2) - 1)){
|
|
$line2[$b]=~s/\W//g;
|
|
$testor = "words/$line2[$b]";
|
|
|
|
if (-e $testor){
|
|
$hurtful = $line2[$b+1];
|
|
$hurtful=~s/\W//g;
|
|
open (FUXOFF,"$testor");
|
|
@azzfuck="";
|
|
@azzfuck = <FUXOFF>;
|
|
close(FUXOFF);
|
|
$ratiociner="";
|
|
open (FUXOFF, ">$testor");
|
|
for ($c=0; $c<scalar(@azzfuck); $c++){
|
|
if ($azzfuck[$c] =~ m/$hurtful/){
|
|
($kill, $murder) = split(" ",$azzfuck[$c]);
|
|
$murder = $murder + 1;
|
|
$azzfuck[$c]="$kill $murder\n"; $ratiociner=13;
|
|
}
|
|
|
|
}
|
|
if ($ratiociner==13){print FUXOFF @azzfuck;}
|
|
else {print FUXOFF @azzfuck, $hurtful, " 1\n";}
|
|
close(FUXOFF);
|
|
}
|
|
|
|
else{open(FUXOFF,">$testor");
|
|
$hurtful=$line2[$b+1];
|
|
$hurtful=~s/\W//g;
|
|
print FUXOFF "$hurtful 1\n";
|
|
close(FUXOFF);}}
|
|
}
|
|
|
|
##########
|
|
## [09] ##
|
|
###########################################################################
|
|
## FILENAME: "Tim's Special World"
|
|
## LANGUAGE: C++
|
|
## AUTHOR: Trilobyte
|
|
###########################################################################
|
|
|
|
/* trilobyte's
|
|
-------- TimWorld for BeOS
|
|
-------- The OS of Now
|
|
-------- It Opens a Window
|
|
-------- Try & Figure Out How!
|
|
[[ originally split up into four files and
|
|
a resource file (for the icon & version number) ..
|
|
TimWindow.h, TimWindow.cpp, TimWorld.h, TimWorld.cpp
|
|
]]
|
|
*/
|
|
|
|
// OS-includes
|
|
|
|
#include <Application.h>
|
|
#include <Window.h>
|
|
|
|
// define the application object
|
|
|
|
class TimApp : public BApplication
|
|
{
|
|
public:
|
|
TimApp();
|
|
};
|
|
|
|
// define the timwindow object
|
|
|
|
class TimWindow : public BWindow
|
|
{
|
|
public:
|
|
TimWindow(BRect frame); // the window's frame (size)
|
|
// is defined by a BRect object
|
|
virtual bool QuitRequested(); // we need to make our own
|
|
// QuitRequested() so we can be
|
|
// told when we are asked to quit
|
|
};
|
|
|
|
// this isn't needed in this program
|
|
// because i don't need to do anything
|
|
// with the window's constructor
|
|
// to setup the window. the window is
|
|
// very basic and has no added ingredients.
|
|
// uncommenting the commented portion
|
|
// would create another view within
|
|
// the window's view, which would allow
|
|
// me to put a button or picture or
|
|
// something there.
|
|
|
|
TimWindow::TimWindow (BRect frame)
|
|
: BWindow (frame, "TimWorld", B_TITLED_WINDOW,
|
|
B_NOT_RESIZABLE | B_NOT_ZOOMABLE )
|
|
{
|
|
// TimView *timView;
|
|
// BRect timRect( Bounds() );
|
|
}
|
|
|
|
bool TimWindow::QuitRequested()
|
|
{
|
|
be_app->PostMessage(B_QUIT_REQUESTED); // somebody clicked the
|
|
// close-button!
|
|
return(true);
|
|
}
|
|
|
|
// construct the TimApp
|
|
|
|
TimApp::TimApp()
|
|
: BApplication ("application/x-vnd.Tim-TimWorld")
|
|
{
|
|
TimWindow *timWindow; // our window!
|
|
BRect timRect; // all window or view frames
|
|
// use a BRect (rectangle)
|
|
|
|
timRect.Set(100, 80, 260, 120); // the BRect has its Set function
|
|
// to define its size.
|
|
timWindow = new TimWindow(timRect);
|
|
// make our window from the TimWindow
|
|
// object in timRect's size.
|
|
timWindow->Show(); // show the friggin window!
|
|
}
|
|
|
|
// the main loop
|
|
|
|
int main(int, char**) {
|
|
|
|
TimApp timApp;
|
|
|
|
timApp.Run(); // tim runs (in a loop).
|
|
return(0); // tim stops.
|
|
}
|
|
|
|
##########
|
|
## [10] ##
|
|
###########################################################################
|
|
## FILENAME: "AREXX-based HOE Issue Commenter V1.00"
|
|
## LANGUAGE: AREXX
|
|
## AUTHOR: Trilobyte
|
|
###########################################################################
|
|
|
|
/*
|
|
** HOE.rexx
|
|
**
|
|
** AREXX-based HOE Issue Commenter V1.00
|
|
** by trilobyte
|
|
**
|
|
** Creates a filecomment for each hoe issue in a directory
|
|
** containing the story's title and author, taken from
|
|
** a hoe-index.txt in the same dir.
|
|
**
|
|
** REXX is a scripting language developed at IBM. It is
|
|
** a power-tool on the Amiga and on OS/2 and is very powerful
|
|
** at parsing and manipulating strings. AmigaREXX is extensible
|
|
** through the Amiga's system of dynamically loaded libraries.
|
|
**
|
|
** (HOE.REXX Requires rexxdossupport.library)
|
|
*/
|
|
|
|
IF ARG(1, 'E') then Do
|
|
PathArg = STRIP(ARG(1))
|
|
IF ~EXISTS(PathArg) THEN DO
|
|
say PathArg || ' does not appear to exist.'
|
|
Call PrintUsage
|
|
Exit
|
|
END
|
|
END
|
|
ELSE Do
|
|
Call PrintUsage
|
|
Exit
|
|
End
|
|
|
|
If ~Show('L','rexxdossupport.library') Then
|
|
Do
|
|
If ~Addlib('rexxdossupport.library',0,-30,0) Then Do
|
|
say "Couldn't allocate rexxdossupport.library!"
|
|
exit
|
|
end
|
|
End
|
|
|
|
Indexfile = AddPart(PathArg, 'hoe-index.txt')
|
|
|
|
if ~open(File, Indexfile) then do
|
|
say 'Cannot open ' || Indexfile
|
|
exit
|
|
end
|
|
|
|
say 'HOE.rexx V1.00 -- HOE issue commenter by Trilobyte'
|
|
|
|
do while ~ EOF(File)
|
|
Line = readln(File)
|
|
if WORDLENGTH(Line, 1) > 2 then do
|
|
if (COMPARE('THE', WORD(Line,1)) > 0) then do
|
|
if (91 < WORD(Line,1)) & (WORD(Line,1) < 1000) then do
|
|
parse var Line ' ' issue ' -- ' title ' -- ' author
|
|
fn = 'hoe-' || STRIP(issue) || '.txt'
|
|
FileName = AddPart(PathArg, fn)
|
|
Cmnt = title || ' by ' || author
|
|
if EXISTS(FileName) then do
|
|
Call SetComment FileName,Cmnt
|
|
Say 'Issue #' || issue || ': ' || Cmnt
|
|
end
|
|
end
|
|
end
|
|
end
|
|
else
|
|
iterate
|
|
end
|
|
close(File)
|
|
RemLib('rexxdossupport.library')
|
|
Exit
|
|
|
|
PrintUsage:
|
|
say 'Usage : rx HOE [path to hoe-files]'
|
|
say 'Example : rx HOE Sys:Hoe/'
|
|
exit
|
|
RETURN
|
|
|
|
##########
|
|
## [12] ##
|
|
###########################################################################
|
|
## FILENAME: "Hooker's Babble"
|
|
## LANGUAGE: Tcl/Eggdrop
|
|
## AUTHOR: Gaurdian (Modified by Mogel)
|
|
###########################################################################
|
|
|
|
# This is a pretty annoying eggdrop script that we used to run on the
|
|
# original #dto (doomed to obscurity) bot back in '96. Her name was
|
|
# Hooker. Hooker would dump a random line from babble.txt every 5
|
|
# minutes. Sometimes it was annoying, sometimes it was hilarious--and
|
|
# something it would quite mysteriously relate completely to the
|
|
# conversation at hand.
|
|
|
|
set sayfile /home/dto/hooker/scripts/babble.txt
|
|
set saystuffchannel #dto
|
|
|
|
if {![info exists saystuffactive]} {
|
|
utimer 450 saystuff
|
|
set saystuffactive 30
|
|
}
|
|
|
|
proc saystuff {} {
|
|
global sayfile saystuffchannel
|
|
|
|
set fd [open $sayfile r]
|
|
set found 0
|
|
while {![eof $fd]} {
|
|
set inp [gets $fd]
|
|
incr found
|
|
}
|
|
|
|
set numiwant [expr [rand $found] + 1]
|
|
set found 0
|
|
close $fd
|
|
set fd [open $sayfile r]
|
|
|
|
while {![eof $fd]} {
|
|
set inp [gets $fd]
|
|
if {[eof $fd]} {break}
|
|
incr found
|
|
if {$found == $numiwant} {break}
|
|
}
|
|
|
|
close $fd
|
|
putserv "PRIVMSG $saystuffchannel :$inp"
|
|
utimer 300 saystuff
|
|
return 1
|
|
}
|
|
|
|
putlog "#babble.tcl v1.0 loaded and active"
|
|
|
|
##########
|
|
## [12] ##
|
|
###########################################################################
|
|
## FILENAME: "Eggdrop Defintions By Question"
|
|
## LANGUAGE: Tcl/Eggdrop
|
|
## AUTHOR: Gaurdian (Modified by Mogel)
|
|
###########################################################################
|
|
|
|
# This script was written for eggdrop bots to remember and recall
|
|
# defintions for things based on the "is" association.
|
|
# If you were to say "mogel is an idiot" it would recall that value, and
|
|
# later, if it sees "mogel?" within any statement on a channel, it will
|
|
# respond with "mogel is an idiot".
|
|
|
|
# for some reason the bot needs to initialize with two blank (0k) text
|
|
# files called "bleh1.txt" and "bleh2.txt". make sure these exist.
|
|
|
|
set lfile1 /home/dto/hooker/scripts/bleh1.txt
|
|
set lfile2 /home/dto/hooker/scripts/bleh2.txt
|
|
|
|
bind pubm - * learntcl
|
|
bind msgm - * learntclmsg
|
|
|
|
proc learntclmsg {nick user handle text} {
|
|
if {[learntcl $nick $user $handle $nick $text] != 2} {
|
|
# replystuff $nick $user $handle $text
|
|
}
|
|
}
|
|
|
|
proc learntcl {nick user handle channel text} {
|
|
global lfile1 lfile2 quelen
|
|
set ltext [string trim $text]
|
|
|
|
### parse the user's text
|
|
|
|
# ignore if statements... unfortunately, ignore words with 'if' in them
|
|
# if {[string first if [string tolower $ltext]] >= 0} {return 1}
|
|
|
|
# fix up strings like: "dog????"
|
|
set temp [lsearch [string tolower $ltext] is]
|
|
if {($temp == -1) && ([llength $ltext] == 1)} {
|
|
if {[string first ? "$ltext" ] <= 0} {return 1}
|
|
set ltext "what is $ltext"
|
|
set temp 1
|
|
}
|
|
if {$temp <= 0} {return 1}
|
|
|
|
# isolate the 'keyword' string that we need to look at
|
|
set temp [expr $temp - 1]
|
|
set ltext [lrange $ltext $temp end]
|
|
|
|
### done with string parsing
|
|
|
|
set lfdin [open $lfile1 r]
|
|
set lfdout [open $lfile2 w]
|
|
|
|
set temp [string tolower [lindex $ltext 0]]
|
|
if {($temp == "what") || ($temp == "who")} {
|
|
set matchword [string toupper [string trimright [lindex [string trimright $ltext ?!@#,.] 2] ?!@#,.]]
|
|
putlog "<$nick:$channel> ($text) ($ltext) ($matchword)"
|
|
set returnval 1
|
|
while {![eof $lfdin]} {
|
|
set temp [gets $lfdin]
|
|
if {([string toupper [lindex $temp 0]] == $matchword) && ([string toupper [lindex $temp 1]] == "IS")} {
|
|
set typingdelay [expr [expr [string length $temp] / 10] + 5]
|
|
#utimer $typingdelay "putserv \042PRIVMSG $channel :$temp\042"
|
|
set queargs "putserv \042PRIVMSG $channel :$temp\042"
|
|
if {![info exists quelen]} {
|
|
set quelen 1
|
|
} {set quelen [expr $quelen + 1]}
|
|
dynamicque $typingdelay $queargs
|
|
putlog "(delayed by $typingdelay secs) -> $channel :($temp)"
|
|
set returnval 2
|
|
}
|
|
}
|
|
close $lfdin
|
|
close $lfdout
|
|
return $returnval
|
|
}
|
|
|
|
while {![eof $lfdin]} {
|
|
set temp [gets $lfdin]
|
|
if {[string toupper [lindex $temp 0]] == [string toupper [lindex $ltext 0]]} {
|
|
puts $lfdout "$ltext"
|
|
set lchange 1
|
|
} elseif {$temp != "" } { puts $lfdout "$temp" }
|
|
}
|
|
|
|
if {![info exists lchange]} {
|
|
puts $lfdout "$ltext"
|
|
}
|
|
|
|
putlog "<$nick:$channel> $text ($ltext)"
|
|
|
|
close $lfdin
|
|
close $lfdout
|
|
exec cat $lfile2 > $lfile1
|
|
return 3
|
|
}
|
|
|
|
proc dynamicque {quetime command} {
|
|
global queinprogress quelen
|
|
if {[info exist queinprogress]} {
|
|
utimer 1 "dynamicque $quetime {$command}"
|
|
return 0
|
|
}
|
|
if {$quelen < 8} {
|
|
set queinprogress 1
|
|
utimer $quetime $command
|
|
utimer $quetime decque
|
|
} elseif {$quelen < 9 } {utimer $quetime "putserv \042PRIVMSG [lindex [lindex $command 1] 1] :what are you doing??? stop that.\042"
|
|
utimer $quetime decque
|
|
} else {
|
|
# utimer $quetime decque
|
|
putlog "Overloaded 'dynamic que'... not replying to $command ... oh well."}
|
|
}
|
|
|
|
proc decque {} {
|
|
global quelen queinprogress
|
|
if {[info exist queinprogress]} {unset queinprogress}
|
|
putlog "quelen is $quelen"
|
|
if {$quelen <= 1} {unset quelen} {set quelen [expr $quelen - 1]}
|
|
}
|
|
|
|
[--------------------------------------------------------------------------]
|
|
[ (c) !LA HOE REVOLUCION PRESS! HOE #935, WRITTEN BY V/A - 12/05/99 ]
|