Claim set · data/claims/hamurabi.yaml

Hamurabi (Ahl's BASIC listing and Dyment's FOCAL original)

Game: Hamurabi.

The first report shows 100 people (95 plus 5 arrivals), 1,000 acres, and 2,800 bushels in store, left from a harvest of 3,000 bushels at 3 bushels per acre after rats ate 200. hamurabi/start-state

Value
{
 "people": 100,
 "acres": 1000,
 "bushels": 2800,
 "harvest": 3000,
 "yield": 3,
 "rats": 200
}
CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L6-L20 — BASIC lines 100–218; acres are the harvest over the yield, 3,000 / 3100 Z=0: P=95:S=2800: H=3000: E=H-S 110 Y=3: A=H/Y: I=5: Q=1 … 218 P=P+IChecked by claude, 2026-10-20 — read L6-L21 (BASIC 95-270): the variables, then the first report

Cited by: Hamurabi

The book's description starts the city with 3,000 bushels in storage, but the listing's first report shows 2,800, because rats ate 200 of a 3,000-bushel harvest. hamurabi/store-not-3000

Value: 3000 bushels

CodeBASIC Computer Games: Microcomputer Edition · p. 78The city initially has 1,000 acres, 100 people and 3,000 bushels of grain in storage.BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L7100 Z=0: P=95:S=2800: H=3000: E=H-SChecked by claude, 2026-10-20 — read the description on p. 78 and L7; the book's sample run on p. 78 also shows 2800 BUSHELS IN STORE

Cited by: Hamurabi

Each year land trades at 17+⌊10r⌋ bushels per acre for a random r in [0, 1), a whole number from 17 to 26. hamurabi/land-price

About: Hamurabi Commodity trading

Value
{
 "min": 17,
 "max": 26,
 "distribution": "uniform"
}
CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L22-L23310 C=INT(10*RND(1)): Y=C+17 312 PRINT "LAND IS TRADING AT";Y;"BUSHELS PER ACRE."BASIC Computer Games: Microcomputer Edition · p. 78the price will vary between 17 and 26 bushels per acreChecked by claude, 2026-10-20 — read L22-L23 (BASIC 310-312); the price is drawn once per year, before both prompts

Cited by: Commodity trading, Hamurabi

The player may buy land at the year's price if the store covers it, and buying any land skips the chance to sell that year. hamurabi/land-buy

About: Hamurabi Commodity trading

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L24-L31322 IF Y*Q<=S THEN 330 … 330 IF Q=0 THEN 340 331 A=A+Q: S=S-Y*Q: C=0 334 GOTO 400Checked by claude, 2026-10-20 — read L24-L31 (BASIC 320-334): 400 is the feeding prompt, so only Q=0 reaches the sale at 340

Cited by: Hamurabi

A sale pays the same price per acre into the store, and the city must keep at least 1 acre. hamurabi/land-sell

About: Hamurabi Commodity trading

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L32-L37342 IF Q<A THEN 350 … 350 A=A-Q: S=S+Y*Q: C=0Checked by claude, 2026-10-20 — read L32-L37 (BASIC 340-350); Q<A refuses a sale of every acre

Cited by: Hamurabi

Each person eats 20 bushels a year, so the number fed is the bushels given divided by 20, rounded down. hamurabi/food

Value: 20 bushels per person per year

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L74-L75539 REM *** HOW MANY PEOPLE HAD FULL TUMMIES? 540 C=INT(Q/20)Checked by claude, 2026-10-20 — read L39-L46 (feeding) and L74-L75

Cited by: Hamurabi

Seed costs half a bushel per acre planted, rounded down, and must come from the store left after feeding. hamurabi/seed

Value: 0.5 bushels per acre

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L54-L55449 REM *** ENOUGH GRAIN FOR SEED? 450 IF INT(D/2)<=S THEN 455BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L62510 S=S-INT(D/2)Checked by claude, 2026-10-20 — read L46-L62; feeding subtracts from S at L46 (BASIC 430) before the seed check

Cited by: Hamurabi

One person can farm 10 acres, but Ahl's check is strict, so P people may plant at most 10P−1 acres, where Dyment's FOCAL allows 10P. hamurabi/tending

Value: 10 acres per person

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L58-L60454 REM *** ENOUGH PEOPLE TO TEND THE CROPS? 455 IF D<10*P THEN 510 460 PRINT "BUT YOU HAVE ONLY";P;"PEOPLE TO TEND THE FIELDS! NOW THEN,"The Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L36 — FOCAL's IF jumps to 5.1 when the expression is negative, that is when D ≤ 10P04.65 I (D-10*P-1)5.1The Sumer Game: DECUS Program Library Write-up, FOCAL8-5 · p. 1, Abstractone person can plant and harvest 10 acresChecked by claude, 2026-10-20 — read L58-L61 and f0005.fc L36; the DECUS write-up states the rule

Cited by: Hamurabi

The yield is a whole number of bushels per acre from 1 to 5, each equally likely, and the harvest is the yield times the acres planted. hamurabi/harvest

Value
{
 "min": 1,
 "max": 5,
 "distribution": "uniform"
}
CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L63-L65511 GOSUB 800 512 REM *** A BOUNTIFUL HARVEST! 515 Y=C: H=D*Y: E=0BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L92800 C=INT(RND(1)*5)+1Checked by claude, 2026-10-20 — read L63-L65 and the subroutine at L92-L93

Cited by: Hamurabi

A second roll of 1 to 5 sets the rats loose when it is even, 2 times in 5, and they eat the store divided by the roll (half on a 2, a quarter on a 4) before the harvest goes in. hamurabi/rats

Value
{
 "chance": 0.4,
 "eats": {
  "2": 0.5,
  "4": 0.25
 }
}
CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L66-L70521 GOSUB 800 522 IF INT(C/2)<>C/2 THEN 530 523 REM *** RATS ARE RUNNING WILD!! 525 E=INT(S/C) 530 S=S-E+HChecked by claude, 2026-10-20 — read L66-L70; S at L69 is the store after feeding and seed, and H is added after E is taken

Cited by: Hamurabi

Arrivals are ⌊c(20A+S)/(100P)+1⌋, where c is a third roll of 1 to 5, A the acres, S the store after harvest and rats, and P the population before starvation. hamurabi/immigration

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L71-L73531 GOSUB 800 532 REM *** LET'S HAVE SOME BABIES 533 I=INT(C*(20*A+S)/P/100+1)Checked by claude, 2026-10-20 — read L71-L73; P changes only at L82, after this line

The arrivals join at the next report (BASIC 218), before the plague check.

Cited by: Hamurabi

A plague halves the population when ⌊10(2r−0.3)⌋≤0, which holds for r<0.2, a 20% chance, though the remark beside it says 15%. hamurabi/plague

Value: 0.2

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L76-L77541 REM *** HORROS, A 15% CHANCE OF PLAGUE 542 Q=INT(10*(2*RND(1)-.3))BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L13-L15227 IF Q>0 THEN 230 228 P=INT(P/2)Checked by claude, 2026-10-20 — read L76-L77 and L13-L15; 10(2r - 0.3) = 20r - 3, and its floor is at most 0 exactly when 20r - 3 < 1

The roll is made at the end of a year and applied at the next report, after the arrivals join. Q starts at 1 (BASIC 110), so the first report never has a plague. DEC's 1975 printing has the same formula and the same remark (p. 129, lines 541–542).

Cited by: Hamurabi

Everyone not fed dies, and the population becomes the number fed; a surplus kills no one and the population stays. hamurabi/starvation

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L78-L82550 IF P<C THEN 210 … 552 D=P-C: IF D>.45*P THEN 560 … 555 P=C: D1=D1+D: GOTO 215Checked by claude, 2026-10-20 — read L75-L82; line 210 sets D=0 and returns to the report

Cited by: Hamurabi

Starving more than 45% of the population in one year gets the ruler impeached and ends the game. hamurabi/impeachment

Value: 0.45

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L79-L86551 REM *** STARVE ENOUGH FOR IMPEACHMENT? 552 D=P-C: IF D>.45*P THEN 560 560 PRINT: PRINT "YOU STARVED";D;"PEOPLE IN ONE YEAR!!!" 565 PRINT "DUE TO THIS EXTREME MISMANAGEMENT YOU HAVE NOT ONLY" 566 PRINT "BEEN IMPEACHED AND THROWN OUT OF OFFICE BUT YOU HAVE"Checked by claude, 2026-10-20 — read L79-L86; 567 ends with GOTO 990, the closing message

Cited by: Hamurabi

A year with food to spare skips the update of the average starvation rate P1, so the next update counts that year at the old average instead of 0%. hamurabi/average-skip

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L78-L81550 IF P<C THEN 210 … 553 P1=((Z-1)*P1+D*100/P)/ZChecked by claude, 2026-10-20 — read L78-L82: 550 jumps past 553 whenever more people are fed than exist; 553 weights the stored P1 by Z-1 years

Starve 20% in year 1 and overfeed for nine years, and P1 stays 20: the final rating calls the term heavy-handed. Feeding exactly enough (P = C) does run 553 with D = 0. DEC's 1975 printing has the same lines (p. 129, 550–555).

Cited by: Hamurabi

A term is 10 years of decisions; the 11th report ends the game with the rating. hamurabi/term

Value: 10 years

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L10215 PRINT:PRINT:PRINT "HAMURABI: I BEG TO REPORT TO YOU,": Z=Z+1BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L21270 IF Z=11 THEN 860Checked by claude, 2026-10-20 — read L9-L21: Z counts reports, and 860 is the rating

Cited by: Hamurabi

The final rating tests the average yearly share starved, P1, and the acres per person, L, against three pairs of limits, and the first pair the ruler fails sets the verdict. hamurabi/rating

Value
[
 {
  "verdict": "impeached",
  "starvedOver": 33,
  "acresUnder": 7
 },
 {
  "verdict": "smacks of Nero and Ivan IV",
  "starvedOver": 10,
  "acresUnder": 9
 },
 {
  "verdict": "could have been somewhat better",
  "starvedOver": 3,
  "acresUnder": 10
 },
 {
  "verdict": "a fantastic performance"
 }
]
CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L97-L116865 PRINT D1;"PEOPLE DIED!!": L=A/P … 880 IF P1>33 THEN 565 885 IF L<7 THEN 565 890 IF P1>10 THEN 940 892 IF L<9 THEN 940 895 IF P1>3 THEN 960 896 IF L<10 THEN 960 900 PRINT "A FANTASTIC PERFORMANCE!!! CHARLEMANGE, DISRAELI, AND" … 940 PRINT "YOUR HEAVY-HANDED PERFORMANCE SMACKS OF NERO AND IVAN IV." … …Checked by claude, 2026-10-20 — read L97-L119 (BASIC 860-999); 565 prints the impeachment text without the one-year line

Over 33% or under 7 acres: impeached. Over 10% or under 9: Nero and Ivan IV. Over 3% or under 10: "somewhat better", with a random count of people who would like to see you assassinated. Otherwise: Charlemagne, Disraeli, and Jefferson. The city starts at 10 acres per person.

Cited by: Hamurabi

Ahl's BASIC still sets C to 0 after a land trade and to 1 after feeding, values nothing reads before the next dice roll overwrites C, because in Dyment's FOCAL those lines reset the steward's patience. hamurabi/vestigial-c

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L30331 A=A+Q: S=S-Y*Q: C=0BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L37350 A=A-Q: S=S+Y*Q: C=0BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L46430 S=S-Q: C=1: PRINTThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L2603.90 S A=A+Q;S S=S-Y*Q;S C=0The Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L3004.20 S S=S-Q;S C=1Checked by claude, 2026-10-20 — traced C from L30, L37, and L46: lines 440-510 never read it, and GOSUB 800 (L63) assigns it first

Cited by: Hamurabi

Ahl's steward answers an impossible order with "THINK AGAIN" and asks again as often as needed, and only a negative number ends the game. hamurabi/retry

CodeBASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L24-L28321 INPUT Q: IF Q<0 THEN 850 322 IF Y*Q<=S THEN 330 323 GOSUB 710 324 GOTO 320BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L87-L96710 PRINT "HAMURABI: THINK AGAIN. YOU HAVE ONLY" … 850 PRINT: PRINT "HAMURABI: I CANNOT DO WHAT YOU WISH." 855 PRINT "GET YOURSELF ANOTHER STEWARD!!!!!"Checked by claude, 2026-10-20 — read every GOSUB 710 and 720 (L27, L35, L44, L52, L56) and each one's GOTO back to its prompt

Cited by: Hamurabi

DEC's 1975 printing of the listing has the same rules and constants as the 1978 edition, except that its seed check, INT(D/2)<S, refuses a planting that would use the last bushel. hamurabi/editions

Publisher101 BASIC Computer Games · p. 129, line 450450 IF INT(D/2)<S THEN 455BASIC Computer Games: Microcomputer Edition · p. 79, line 450450 IF INT(D/2)<=S THEN 455BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L55450 IF INT(D/2)<=S THEN 455Checked by claude, 2026-10-20 — compared both scanned listings line by line (lines 100-896); the other differences are wording, RANDOMIZE, and RND(0) for RND(1)

The 1975 printing is the third; the first, July 1973, wasn't available to compare. Dyment's FOCAL check (I (FITR(D/2)-S-1)4.65, f0005.fc line 32) allows the last bushel, as 1978 does.

Cited by: Hamurabi

Dyment's FOCAL program starts from the state Ahl kept, 95 people with 5 arriving, 1,000 acres, and 2,800 bushels after a 3,000-bushel harvest at 3 per acre and 200 lost to rats. hamurabi/focal-start

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L401.10 S P=95;S S=2800;S H=3000;S E=200;S Y=3;S A=1000;S I=5;S Q=1Checked by claude, 2026-10-20 — read f0005.fc L4 and compared hammurabi.bas L7-L8

Cited by: Hamurabi

Dyment's land costs 17 plus a roll of 1 to 5, so 18 to 22 bushels per acre, which matches his write-up's average of "one acre for 20 bushels of grain". hamurabi/focal-land-price

Value
{
 "min": 18,
 "max": 22
}
CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L18-L1903.10 D 6;D 8;S Y=C+17;T "THIS YEAR, LAND MAY BE TRADED FOR 03.20 T Y," BUSHELS PER ACRE;";S C=1The Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L5408.10 S C=FITR(5*FABS(FRAN()))+1The Sumer Game: DECUS Program Library Write-up, FOCAL8-5 · p. 1, AbstractThe price varies from year to year, but averages one acre for 20 bushels of grain.Checked by claude, 2026-10-20 — read f0005.fc L18-L19 and L54 (D 8 calls group 8, the 1-5 roll)

The scanned listing prints line 03.10 as "D 6;D -;S Y=C+17"; the transcription has "D 8". Ahl's BASIC widens the range to 17–26 (land-price).

Cited by: Commodity trading, Hamurabi

Dyment's program has no term or rating, and after each report it asks whether to continue. hamurabi/focal-continue

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L14-L1602.60 T !S," BUSHELS IN STORE."!!!"DO YOU WISH TO CONTINUE? 02.70 A " (ANSWER YES OR NO)"Q,!;I (Q-0NO)2.8,7.4Checked by claude, 2026-10-20 — read all of f0005.fc; no variable counts years

Cited by: Hamurabi

Starvation in Dyment's program only kills, and no number of deaths ends the game. hamurabi/focal-no-impeachment

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L4405.40 S Q=FITR(10*FABS(FRAN()));I (P-C)2.1;S D=P-C;S P=C;G 2.2Checked by claude, 2026-10-20 — read f0005.fc L44 and the report at L6-L16

Cited by: Hamurabi

Dyment's plague halves the population when ⌊10⋅|FRAN()|⌋=0. hamurabi/focal-plague

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L44S Q=FITR(10*FABS(FRAN()))The Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L8-L9I (-Q)2.3 02.27 S P=FITR(P/2);T !"HALF THE PEOPLE DIED FROM A PLAGUE EPIDEMIC,Checked by claude, 2026-10-20 — read L8-L9 and L44: the IF skips to 2.3 only when -Q is negative, so Q = 0 falls through to the plague

One chance in 10 if FRAN() is uniform; the write-up says FOCAL's FRAN() is "not adequate" for the game and prints a patch.

Cited by: Hamurabi

Dyment's steward has a patience counter, C, and when an impossible order finds it below zero, "HAMURABI HAS GONE ON STRIKE" and the game ends. hamurabi/focal-patience

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L48-L5107.10 I (C)7.2;S C=C-1;D 6;T "PLEASE THINK AGAIN. YOU HAVE ONLY";R 07.20 T !"HAMURABI HAS GONE ON STRIKE! YOU WILL HAVE TO STOP 07.30 T !"AND FIND YOURSELF ANOTHER STEWARD!"!!The Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L19S C=1The Sumer Game: DECUS Program Library Write-up, FOCAL8-5 · p. 4, variablesHamurabi's "patience counter"Checked by claude, 2026-10-20 — read L48-L51, then every assignment to C (L19, L24, L26, L30, L41-L43, L54)

C starts each year at 1 (03.20), so the third impossible order in a row ends the game; a land trade sets it to 0 and feeding back to 1. A negative answer ends the game at once (7.2).

Cited by: Hamurabi

Ahl's BASIC keeps Dyment's rules for seed, the harvest, rats, arrivals, and food, down to the arrivals formula c(20A+S)/P/100+1. hamurabi/focal-same-rules

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L41-L4305.10 S S=S-FITR(D/2);D 8;S Y=C;S H=D*Y 05.20 D 8;S E=0;I (FITR(C/2)-C/2)5.3;S E=S/C 05.30 S S=S-E+H;D 8;S I=FITR(C*(20*A+S)/P/100+1);S C=FITR(Q/20)BASIC Computer Games, updated for 2022 (coding-horror/basic-computer-games) · 43_Hammurabi/hammurabi.bas#L62-L75510 S=S-INT(D/2) … 515 Y=C: H=D*Y: E=0 … 522 IF INT(C/2)<>C/2 THEN 530 … 525 E=INT(S/C) 530 S=S-E+H … 533 I=INT(C*(20*A+S)/P/100+1) … 540 C=INT(Q/20)Checked by claude, 2026-10-20 — compared f0005.fc L41-L44 with hammurabi.bas L62-L82, statement by statement

Ahl rounds the rats' share down (INT(S/C)), where FOCAL keeps the fraction. The differences that matter are elsewhere: the price range, the plague odds, the tending check, the 10-year term, impeachment, and the rating.

Cited by: Hamurabi

Dyment's DECUS listing already spells the steward's name HAMURABI, with one m. hamurabi/spelling

CodedisputedThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L4606.10 T !!"HAMURABI: "%5The Sumerian Game: The Most Important Video Game You've Never Heard Of · 2021 Updateit's unlikely that the misspelling of “Hamurabi” was due to space limitations, as it's also present in the longer DECUS versionChecked by claude, 2026-10-20 — read f0005.fc L46 and the scanned listing, DECUS write-up p. 3

Disputed: Ahl's 1978 note says "somewhere along the line an m was dropped out of the spelling of Hammurabi in the Ahl version of the computer program" (ahl-1978-basic-computer-games, p. 78). Richard Moss writes that the m was dropped "in order to fit an eight-character naming limit" (moss-2015-city-building-games). DEC's 1973 book files the program as HMRABI.

Cited by: Hamurabi

Dyment's steward opens each year with "I BEG TO REPORT", and The Sumerian Game reported spoiled grain with "Sir: I am sorry to report". hamurabi/report-line

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L702.20 D 6;T "I BEG TO REPORT THAT LAST YEAR"D," DIED OF STARVATION,The Production and Evaluation of Three Computer-Based Economics Games for the Sixth Grade: Final Report · p. 15Sir: I am sorry to report that bushels of grain have rotted or been eaten by rats this past seasonThe Sumerian Game: The Most Important Video Game You've Never Heard Of · 2021 UpdateSurprisingly, the DECUS version includes the famous line “I beg to report!”Checked by claude, 2026-10-20 — read f0005.fc L7 and L46 (06.10 prints the name first), and Wing et al. p. 15

Kate Willaert drew this connection; Ahl's line 215 reads "HAMURABI: I BEG TO REPORT TO YOU,".

Cited by: Hamurabi

The DECUS listing opens with the line C-FOCAL , 8/68. hamurabi/focal-header

CodeThe Sumer Game, FOCAL source (DECUS FOCAL8-5) · f0005.fc#L2C-FOCAL , 8/68Checked by claude, 2026-10-20 — read f0005.fc L1-L4 and the scanned listing (DECUS write-up p. 3)

No source read here says whether 8/68 dates the FOCAL interpreter or the program.

Cited by: Hamurabi

DECUS's November 1969 catalog lists The Sumer Game, FOCAL-5, by Doug Dyment of Digital Equipment of Canada, "a simulation program/game which will run on a minimal PDP-8 system". hamurabi/decus-1969

PublisherDECUS Program Library Catalog, November 1969 · p. 18-A, DECUS No. FOCAL-5This is a simulation program/game which will run on a minimal PDP-8 system. The economy of a Sumerian city in the year 3000 B.C. is simulated in the fashion of a modern-day "business game."Checked by claude, 2026-10-20 — read the entry on p. 18-A (PDF page 90) and the title page

Cited by: Commodity trading, Hamurabi

Kate Willaert reports that the game was printed as King of Sumeria in DEC's Focal-8 Demonstration Programs in July 1970, and that Dyment wrote a much more compact revision a year or so after the DECUS version. hamurabi/focal8-demo-1970

WebThe Sumerian Game: The Most Important Video Game You've Never Heard OfKing Of Sumeria appeared in the DECUS Program Library Catalog as early as November 1969 under the title The Sumer Game, and under its proper name in DEC’s Focal-8 Demonstration Programs in July 1970.The Sumerian Game: The Most Important Video Game You've Never Heard Of · 2021 Updatenot Dyment’s much more compact revision from a year or so later

Cited by: Hamurabi

Wikidata's item for Hamurabi also covers Dyment's FOCAL program, under the aliases The Sumer Game and King of Sumeria, and gives 1969 as its year. hamurabi/wikidata-1969

WikidataWikidata · Q1646143 (data/catalog/games.json)+1969-00-00T00:00:00Z

The catalog row also lists the aliases "The Sumer Game" and "King of Sumeria", and the HP 3000 as its platform.

Cited by: Hamurabi

DECUS's June 1968 catalog lists no FOCAL programs, and its one program by Dyment is a Sentence Generator (8-112). hamurabi/decus-1968

PublisherDECUS Program Library Catalog, June 1968 · DECUS No. 8-112This program generates random English language sentencesChecked by claude, 2026-10-20 — searched the OCR text for FOCAL, Sumer, and Dyment, then read the 8-112 entry

Cited by: Hamurabi

Richard Moss dates The Sumer Game to 1968, on a PDP-8 in FOCAL. hamurabi/moss-1968

WebFrom SimCity to, well, SimCity: The history of city-building gamesHe coded The Sumer Game in 1968 on a Digital Equipment Corporation PDP-8 minicomputer, using the FOCAL programming language.

The article cites no source for the year.

Cited by: Hamurabi

Ahl's source note in the DEC book says the FOCAL program "has been floating around DIGITAL for nine or more years". hamurabi/ahl-nine-years

Publisherdisputed101 BASIC Computer Games · p. 128, SourceThis is translated from the original FOCAL program which has been floating around DIGITAL for nine or more years.Checked by claude, 2026-10-20 — read p. 128 of the March 1975 printing

Disputed: Nine years before the first printing (July 1973) is 1964, the year of The Sumerian Game's dated printout. The earliest dated listing of Dyment's program found is November 1969 (decus-1969).

Cited by: Hamurabi

DEC's printing of the listing opens with a remark that it was "converted from the original FOCAL program and modified for EduSystem 70 by David Ahl, Digital". hamurabi/focal-remark

Publisher101 BASIC Computer Games · p. 129, lines 10–2010 REM *** CONVERTED FROM THE ORIGINAL FOCAL PROGRAM AND MODIFIED FOR 20 REM *** EDUSYSTEM 70 BY DAVID AHL, DIGITALChecked by claude, 2026-10-20 — read the scanned listing on p. 129 at 260 dpi

Cited by: Hamurabi

Ahl's 1978 note says the program was "originally written in Focal at DEC; author unknown", and that he converted it to BASIC and added the 10-year performance assessment. hamurabi/ahl-added-term

PublisherBASIC Computer Games: Microcomputer Edition · p. 78This program was originally written in Focal at DEC; author unknown. David Ahl converted it to BASIC and added the 10-year performance accessment.Checked by claude, 2026-10-20 — read p. 78 at 250 dpi; "accessment" is the book's spelling

Cited by: Hamurabi

DEC's 101 BASIC Computer Games, first printed in July 1973, includes the game as HMRABI, "Govern the ancient city-state of Sumeria". hamurabi/book-1973

Publisher101 BASIC Computer Games · copyright page and contents1st Printing July 1973101 BASIC Computer Games · contents, p. 4HMRABI Govern the ancient city-state of Sumeria 128Checked by claude, 2026-10-20 — read the copyright page and contents of the March 1975 printing

Cited by: Hamurabi

Creative Computing's 1978 BASIC Computer Games, converted to Microsoft BASIC by Steve North, prints the game as "Hammurabi" on pages 78 and 79. hamurabi/book-1978

PublisherBASIC Computer Games: Microcomputer Edition · title pageProgram Conversion by Steve NorthBASIC Computer Games: Microcomputer Edition · p. 79, line 1010 PRINT TAB(32);"HAMURABI"Checked by claude, 2026-10-20 — read the title page, the copyright page, and pp. 78-79

The page heading reads "Hammurabi"; the program still prints HAMURABI.

Cited by: Hamurabi

Doug Dyment, then at DEC in Canada, told Kate Willaert he wrote the game, which he titled King of Sumeria, as a demonstration program after a graduate student at a university in Alberta described The Sumerian Game to him. hamurabi/dyment-origin

InterviewDoug Dyment on King of Sumeria, interviewed by Kate Willaert — Willaert's preceding sentence gives the graduate student and the talk in Alberta.“I thought that this would make a good demonstration program,” Dyment told me. “The game as I wrote it was titled King Of Sumeria.”Checked by claude, 2026-10-20 — read the "King Of Sumeria" section of the article

Cited by: Hamurabi, The Sumerian Game

Hamurabi descends from The Sumerian Game through Dyment's FOCAL Sumer Game, which Ahl converted to BASIC, and which Dyment based on a description of The Sumerian Game. hamurabi/lineage

Publisher101 BASIC Computer Games · p. 129, line 10CONVERTED FROM THE ORIGINAL FOCAL PROGRAMDoug Dyment on King of Sumeria, interviewed by Kate Willaert“I thought that this would make a good demonstration program,” Dyment told me.The Sumerian Game: The Most Important Video Game You've Never Heard Of · 2021 Updatethe BASIC version that appears in David Ahl's 101 BASIC was adapted from this DECUS version, not Dyment's much more compact revision from a year or so laterChecked by claude, 2026-10-20 — read the three passages; the code comparison is in focal-start, focal-same-rules, and vestigial-c

Cited by: Hamurabi, The Sumerian Game

Ahl's 1973 book introduces King as one of the "land and resource management games" and tells newcomers to "start with HMRABI". hamurabi/ahl-land-management

Publisher101 BASIC Computer Games · p. 138, KINGThis is one of the more comprehensive, difficult, and interesting land and resource management games. (If you've never played one of these games, start with HMRABI).Checked by claude, 2026-10-20 — read p. 138 of the March 1975 printing

Cited by: Hamurabi

Joachim Froholt writes that Hamurabi "is considered a foundational pillar in the strategy genre and an ancestor of today's city-building and empire-management games". hamurabi/froholt-strategy

WebThe Sumerian Game: The ancestor of modern city buildersThis game is considered a foundational pillar in the strategy genre and an ancestor of today’s city-building and empire-management games.

Froholt's next sentence hedges: "it would be unwise to say that these genres wouldn't have existed in anything like their current form without Hamurabi".

Cited by: Hamurabi

Historian Andrea Contato says others used Hamurabi as inspiration for derivative games, and that the city and empire management genre that followed led "to titles like SimCity and eventually Civilization, much later". hamurabi/contato-derivatives

WebThe Sumerian Game: The ancestor of modern city builders — Contato's answer in the interviewOthers used it as inspiration to build derivative games, and the city/empire simulation-management genre became highly popular, leading to titles like SimCity and eventually Civilization, much later.

Contato names no specific derivative of Hamurabi in this passage.

Cited by: Hamurabi

Fraser Brown's history of the strategy game calls Hamurabi "a strategy precursor". hamurabi/brown-precursor

WebThe history of the strategy gameA text-based management game that tasked players with distributing resources to their citizens, Hamurabi was a strategy precursor that could be found in schools and on mainframes in the ’60s.

The ’60s date belongs to The Sumer Game, not Ahl's BASIC version.

Cited by: Hamurabi

Richard Moss calls The Sumer Game "the first computer game to concern itself with matters of city building and management". hamurabi/moss-city-building

WebFrom SimCity to, well, SimCity: The history of city-building gamesWhile extremely limited in its simulation, Doug Dyment’s The Sumer Game was the first computer game to concern itself with matters of city building and management.

Moss's word; the atlas says "earliest known". The article doesn't mention The Sumerian Game, which is earlier (sumerian-game/project).

Cited by: Hamurabi

Jerry Pournelle used Hammurabi as a yardstick for later strategy games, calling M.U.L.E. "a cross between Hammurabi, Diplomacy, and an arcade game" in 1984 and Anacreon "a kind of super Hammurabi" in 1989. hamurabi/pournelle

MagazineComputing at Chaos Manor: NCC Reflections · p. 378M.U.L.E. is a cross between Hammurabi, Diplomacy, and an arcade game, with lots of subtle strategic decisionsComputing at Chaos Manor: To the Stars · p. 115Anacreon (the name is based on one of the barbarian kingdoms in Isaac Asimov's Foundation series), like all the Stellar Conquest derivatives, is a kind of super Hammurabi, with provision for rather simple combat thrown in.

Pournelle compares; he doesn't say either game was derived from Hammurabi. In 1989 he adds that "Half the people I know wrote a Hammurabi program back in the 1970s".

Cited by: Hamurabi

Richard Moss counts George Blank's Santa Paravia and Fiumaccio (1978) as the most notable of the "expanded versions" of The Sumer Game that kept "the same core systems". hamurabi/santa-paravia

About: Q3949220

WebFrom SimCity to, well, SimCity: The history of city-building gamesseveral more expanded versions soon emerged, with different localities but the same core systems. Of these, George Blank’s 1978 Apple II game Santa Paravia and Fiumaccio was perhaps the most notable

Blank's own article (SoftSide 1, no. 3, December 1978) doesn't mention Hamurabi. Moss gives the game as Apple II, but SoftSide printed it for the TRS-80.

Cited by: Hamurabi

Walter Bright says he typed in Hamurabi from a book of BASIC listings in high school, expanded it at Caltech under the name King, and turned to Empire when he tired of it. hamurabi/bright-king

Dev blogA Brief History of Empire · Prehistory, First VersionsOne that interested me was printed in a book of Basic game listings, called Hamurabi. I punched it in, and started to modify it. … I got the operator to load in my Hamurabi deck, renamed it to King, and spent the next semester learning how to enhance it. … Tiring of King, I remembered that old game I'd invented as a kid.

Bright names the film Battle of Britain and the board game Risk as Empire's inspirations, not Hamurabi. Empire (1977) has no row in the games catalog.

Cited by: Hamurabi

DECUS's 1978 PDP-8 catalog lists a French "version of HAMURABI (the Sumer Game)" by J. F. Champarnaud and F. H. Bostem of Liège, and RUBEN, "a modification of the 'King of Sumeria' game" by James R. B. Howard II and Jimmie B. Fletcher. hamurabi/decus-variants

PublisherDECUS PDP-8 Program Library Catalog, August 1978 · p. 71, FOCAL8-186This French language version of HAMURABI (the Sumer Game) is available on both paper tape and PDP-12 LINCtape.DECUS PDP-8 Program Library Catalog, August 1978 · p. 83, FOCAL8-305A modification of the "King of Sumeria" game. Problems with the random number generator have been corrected and some additional features have been added.Checked by claude, 2026-10-20 — read both entries in the scan (pp. 71 and 83)

Cited by: Hamurabi