S
S
sashx2021-10-05 08:12:04
C++ / C#
sashx, 2021-10-05 08:12:04

What does the given number 0x55555555555555551 mean in C++?

Maybe a stupid question, but I can't find the answer.
What does a given number return in C++?
0x55555555555555551

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander Ananiev, 2021-10-05
@SaNNy32

The number returns nothing. 0x is the hexadecimal representation of a number.
https://stackoverflow.com/questions/8186965/what-d...

R
rPman, 2021-10-05
@rPman

0x55555555555555551 - hexadecimal system, 9 bytes are required to store it, i.e. can only be written as a 16-byte integer (__int128) or greater, or in classes that support a variable number of bytes for storing numbers. gnu compiler doesn't officially support 128bit constants, so they will have to be entered through strings or assembled manually from numbers of lower capacity
calculator says this is 98382635059784275281 in decimal

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question