In this manuscript, we propose an algorithm based on an artificial neural network (ANN) for the analysis of the NaI(Tl) gamma-ray spectra with radioisotope (RI) mixtures to identify RIs and determine the relative activity levels of the identified RIs. The ANN was trained based on the spectra that were generated by synthesizing previously identified spectra from single RIs, considering the characteristics of the measurement environments, such as gain shift effects and statistical fluctuations in the spectrum. The proposed ANN was evaluated through several measured spectra that contained up to six certified reference materials for a quantitative analysis. We also evaluated the shift in the spectra due to temperature variations in the range of 0-50 degrees C and the low-count spectra with a one-second acquisition period. These results were compared with those from an ANN trained through simulated spectra to emphasize the importance of acquiring a high-quality training dataset. In addition, we show that complex low-resolution spectra can be accurately analyzed with the proposed ANN under various scenarios, in which the maximum root mean square error was found to be 2.8%.