What does 0x mean in c language?

藏色散人
Release: 2020-02-26 09:36:38
Original
25860 people have browsed it

What does 0x mean in c language?

What does 0x mean in C language?

In C language, assigning a value of 0x to a variable uses a hexadecimal number as the value of the variable. of. Generally used to represent memory addresses.

Example:

Define x: int x = 0x23;

This sentence means the same as defining int x=35. When the compiler receives 0x23, it treats it as a hexadecimal number.

Simply put, it means that the value after 0x is hexadecimal.

For more programming related content, please pay attention to the Programming Introduction column on the php Chinese website!

The above is the detailed content of What does 0x mean in c language?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!