Ticker

6/recent/ticker-posts

Ad Code

L5, Octal System, What is Octal System? package q10741

The numbering system which uses base-8 is called Octal System. A base (also called radix) is the number of unique digits or symbols (including 0) used to represent a given number. In Octal System (base-8) a total of 8 digits (0, 1, 2, 3, 4, 5, 6 and 7) are used to represent a number of any size (magnitude).

For exampleZero is represented as 0, where

0 = (
0 * 80) = (0 * 1)

Similarly 1, 2 ...up to 7 One (1):

1 = (1 * 80) = (1 * 1)

2 = (2 * 80) = (2 * 1)
...
7 = (7 * 80) = (7 * 1)

Now, lets try representing Twenty One (21), since 0 to 7 are the only digits we can use to represent 21, let us divide 21 by 8 and write down [quotient][reminder], i.e.: [2][5]

21 = (2 * 81) + (5 * 80) = (16) + (5)

Similarly, lets try representing Four Hundred and Twenty One (421), let us divide 421 by 8 and write down [quotient][reminder], i.e.: [52][5] (further dividing 52 by 8 we get [6][4]), which is [6][4][5]

421 = (6 * 82) + (4 * 81 + (5 * 80) = (384) + (32) + (5)

In Java, Octal numerals are prefixed with a leading 0 (zero). For example, to store an octal value of seven into a variable numberSeven, we write
int numberSeven = 07;

Similarly, if we want to store a octal representation of decimal number 9 into a variable numberNine, we write

int numberNine = 011;

Select all the correct statements given below.

In Octal System the base is 10

In Octal System, Decimal value of 10 is represented as 21

In Octal System, Decimal 8 is represented as 10

In Octal System, Decimal of 10 is written as 012

Post a Comment

0 Comments