This paper describes a method of molecular orbital calculation for heteronuclear and homonuclear diatomic molecules, in the approximation of a linear combination of spatial configurations, each of which is a product of one-electron functions. The method is applicable to systems in which the one-electron orbitals are not required to be either orthogonal or filled in pairs. A practical procedure is presented for treating permutational symmetry and spin for an arbitrary spatial wave function, and using this procedure we consider simultaneously all the spin configurations associated with the chosen spatial wave function. The wave functions used are parametric expressions in spheroidal coordinates, and include the usual Slater orbitals as special cases. All necessary integrals are evaluated in a manner suitable for machine computation. A computer programme to implement this method of calculation has been prepared. Provision was made to programme the computer to vary the parameters of the wave functions so as to find automatically the wave function of minimum energy of the parametric form chosen. Only a part of the calculation need be repeated after varying parameters, and the optimum retention of computed data for re-use is discussed. The evaluation of operators other than the energy is also described. A direct variation method is proposed for calculating electric and magnetic polarizabilities.