Re: Integers
| From: | Shreyas Agasthya | Date: | Thu, 01 Jul 2010 07:59:42 +0000 |
| Subject: | Re: Integers | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-306592@lists.php.net to get a copy of this message | ||
It would also mean that 7 (8 digits which includes 0) is the highest numeric
representation that you can have or go up to in an octal representation.
So to take your example and represent an octal number :
001000101111 (subscript 2) = 1057(subscript 8)
--Shreyas
On Thu, Jul 1, 2010 at 7:42 AM, Stephen <stephen-d@rogers.com> wrote:
> On 10-06-30 10:02 PM, David McGlone wrote:
>
>> Hi again
>>
>> I'm trying to learn about octal numbers and I don't understand this:
>>
>> Binary: 001000101111
>> breakdown: (001)= 1 (000)= 0 (101)=5 (111)=7
>>
>> I know it's similar to unix permissions, but I'm not understanding where
>> for
>> example: 111 = 7
>>
>>
> In base 10, which you use every day, we go
> 0
> 1
> 2
> 3
> 4
> 5
> 6
> 7
> 8
> 9
> 10
>
> The number 10 is the number of distinct digits we use.
>
> In binary we only us two, 0 and 1, so 10 is 2 decimal
>
> So we go
>
> 0 = 0 decimal
> 1 = 1 << important
> 10 = 2 << important
> 11 = 3
> 100 = 4 << important
> 101 = 5
> 110 = 6
> 111 = 7
>
> So binary 111 is 4 + 2 + 1 = 7
>
> Stephen
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
Regards,
Shreyas Agasthya