To compare the efficacy, safety and tolerance, and other clinical and immunologic effects of zidovudine (AZT) plus zalcitabine (dideoxycytidine; ddC), AZT plus didanosine (ddI), and AZT alternating monthly with ddI as measured by differences in survival among HIV-infected persons who have received 6 or more months of nucleoside monotherapy and have a CD4 count greater than or equal to 50 cells/mm3.