# $n^2 - 1$ is divisible by 8, if $n$ is(A) an integer(B) a natural number(C) an odd integer(D) an even integer

#### Complete Python Prime Pack for 2023

9 Courses     2 eBooks

#### Artificial Intelligence & Machine Learning Prime Pack

6 Courses     1 eBooks

#### Java Prime Pack 2023

8 Courses     2 eBooks

Given:

$n^2 - 1$ is divisible by 8.

To do:

We have to find the correct option.

Solution:

Let $a = n^2 - 1$ where $n$ can be even or odd.

When $n$ is even,

$n = 2k$, where $k$ is an integer.

This implies,

$a = (2k)^2 - 1$

$a = 4k^2 - 1$

For $k = -1$,

$a = 4(-1)^2 - 1$

$= 4 - 1$

$= 3$ which is not divisible by 8.

For $k = 0$,

$a = 4(0)^2 - 1$

$= 0 - 1$

$= -1$, which is not divisible by 8.

When $n$ is odd, $n = 2k + 1$, where $k$ is an integer,

This implies,

$a = (2k+1)^2-1$

$=4k^2+4k+1-1$

$=4k^2+4k$

$=4k(k+1)$

For $k = 1$,

$a=4(1)(1 + 1)$

$= 8$ which is divisible by 8.

Hence, we can conclude from the above two observations that if $n$ is odd, then $n^2 - 1$ is divisible by 8.

Updated on 10-Oct-2022 13:27:06