We used the IRAM 30m telescope to observe the frequency range [86-116]GHz towards the central regions of the starburst galaxies M83, M82, and NGC253, the AGNs M51, NGC1068, and NGC7469, and the ULIRGs Arp220 and Mrk231. Assuming LTE conditions, we calculated the column densities of 27 molecules and 10 isotopologues. Among others, we report the first tentative detections of CH3CHO, HNCO, and NS in M82 and, for the first time in the extragalactic medium, HC5N in NGC253. Halpha recombination lines were only found in M82 and NGC253. Vibrationally excited lines of HC3N were only detected in Arp220. CH3CCH emission is only seen in the starburst-dominated galaxies. By comparison of the fractional abundances among the galaxies, we looked for the molecules that are best suited to characterise the chemistry of starbursts, AGNs and ULIRGs, as well as the differences among galaxies within the same group.