La Cucaracha is a Mexican folk song, its satirical verses originating from the time of the Mexican revolution. It is closely associated with figures such as Pancho Villa and Emiliano Zapata. It has many verses, which can vary from incarnation to incarnation. The chorus, however, goes:
La cucaracha, la cucaracha
Ya no puede caminar
Porque no tiene, porque le falta
Marihuana que fumar
Which in English means:
"The cockroach, the cockroach
Can't walk anymore
Because he doesn't have, because he lacks
Marijuana to smoke"
The last line might explain why you probably didn't learn that in your high school Spanish class. A search on Google will in fact reveal that there are several censored versions of this chorus, which do not make reference to a pothead insect.
But, of course, we should not take la cucaracha overly literally. Chances are, la cucaracha was not an actual cockroach, but a satirical symbol for a Mexican revolutionary.