Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to represent a hexadecimal value 1F?

Tags:

php

How to represent a hexadecimal value 1F?

like image 990
Poonam Bhatt Avatar asked Dec 28 '10 11:12

Poonam Bhatt


People also ask

How do you represent a hexadecimal value?

Each Hexadecimal number can be represented using only 4 bits, with each group of bits having a distich values between 0000 (for 0) and 1111 (for F = 15 = 8+4+2+1). The equivalent binary number of Hexadecimal number are as given below. Hexadecimal number system is similar to Octal number system.

What comes after F in hexadecimal?

So Hexadecimal numbers have 16 symbols or digital values, i.e 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F. A, B, C, D, E, F are single bit representations of 10, 11, 12, 13, 14 and 15 respectively.


1 Answers

Just prefix the number with 0x:

$n = 0x1F;
like image 154
codaddict Avatar answered Sep 25 '22 15:09

codaddict