"Cuarenta y dos dólares."
In case you're wondering, $42 also means forty-two dollars and is generally accepted as a more efficient way of writing. Is there anyone on the planet who does know that $ means dollars and 42 means Fort-two. That's how numbers work.
In my experience with Duolingo up to this point in time (7 months of study, level 24, 308 crowns), using the "$" symbol and arabic numerals to express the English answer to a question written in Spanish has been acceptable to the program. If these same questions are used for native Spanish speakers who are trying to learn English, then is makes sense to have us spell out the English. Otherwise, if I haven't learned to spell the English equivalent after 71 years of being a native English speaker, I don't think that having to do it here is going to help. If indeed there are different versions of the course for native English speakers than for native Spanish speakers, is is certainly a waste of my time to have to type out any number, let alone forty-two dollars. "$42" should be an acceptable answer to this question.