C + + full-angle space error unknown character ' 0xa1 '

Source: Internet
Author: User

The network is a good thing to find anything can be found, including the code can be found directly from the web, like lazy beginners of the clock
Love "Ctrl+c+web", but the problem is often not as smooth as we think. Because C + + does not know the full-width spaces at all,
Many of the pages posted in the code before and after each contains one to multiple full-width spaces, the most deadly only by your naked eye is unable to distinguish it and C + + can recognize the difference between the half angle. So often when we are happy to find a piece of code into the compilation environment, the compilation test error comes out, and is a heap of appearance:
Unknown character ' 0xa1 '
Unknown character ' 0xa1 '
Unknown character ' 0xa1 '
...........
How to do, do we really knock again, the code to knock again, the code is less then there is this possibility, but some code hundreds of thousands of lines, knocking once is unlikely.

I have a way here. Put your code in Word, there is an advanced search instead of all the full-width spaces to replace the half-width space can be, of course, if the code is very small, then directly in the editor of each line before and after the space to delete it.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.