How programs 5300 and 5310 work

Program 5300 starts at 1714, where it clears core from 1399 down to 100.
It probably ought to clear down to 0, but that's not how it works.

Then it rewinds tape 1 and loads program 5310, which is the tape loader.
Program 5310 is not executed at this time, but loading it does leave a
group mark with a word mark in 1398.  The last card also leaves B in
location 1 and a blank in column 5.  Then it goes back to program 5300 at
1509.

At 1509 program 5300 puts 1365, the address of the load routine in program
5310, into 2-4 and writes the first tape block, which is the load routine
in program 5310.

Then it copies cards until it finds one with A in column 80, at which time
it sets up the tape write routine's exit to come back to 1600, where it
loads a program, and writes that card, which has the title in 49-72, and,
more importantly, the program code in 73-76.

Then it loads the program by reading the next card and branching to 1.

The last card of the program deck looks at 1398.  If it's a group mark, it
changes the overlay code in the loaded deck so it goes back to the loader
in program 5310, and returns to program 5300 at 1604:

1...5...10...15...20...25...30...35...40...45...50...55...60...65...70...75.
,019027,031,038042B031T98"B400L046352BW04BS88   title                   ####

At 1604, program 5300 sets a GMWM in 1250 sets the exit from the tape
write routine to return to 1546, where it reads detail cards, and writes
writes the program just loaded.

If the last card switch is on and switch G is not on, it writes a tape
mark, rewinds tape 1, and stops.  If the last card switch is on and switch
G is on, it just hangs on a read instruction so you can put more decks in
the hopper.

If programs are loaded from cards, they start at 400.  If they're loaded
from tape they start at 377, which looks at some stuff around 1255 or so,
depending no the program, to decide whether to run the program.  Look at
the manual for each program to see which switch to set.

The code at 377 also modifies itself so that the program loader can also
be used to read detail records.