IQ scores are not inherently affected by autism; however, other conditions that do affect IQ, such as intellectual disabilities or savant syndrome, are comorbid with autism.
This means that autistic people are statistically more likely than neurotypicals to sit on the extreme ends of the intelligence bell curve. It is important to realise that above or below average intellectual ability, if present, is generally due to a separate diagnosis, not the autism itself.
Films like "Rain Man" have promoted the stereotype of autistic people having savant abilities, and contemporary research in medical biography posits historical figures like Mozart, Einstein, Darwin, and Newton as having been on the spectrum. This has contributed to creating an expectation of autism being correlated with giftedness, special talents, and superior intelligence. In reality, while savantism is more common in autistics (approx. 10%) than in the neurotypical population (approx. 1%), it is far from the norm.
Instead, people with autism may have higher aptitude in specific types of tasks that require visual thinking or pattern recognition, which can make it easier to learn certain skills such as foreign languages, musical instruments, or maths. The typically autistic intense focus on a single topic, and relentless study as well as practice, may also contribute to what looks like a special talent.