Hướng dẫn how do you find the range of a composite number in python? - làm thế nào để bạn tìm thấy phạm vi của một số tổng hợp trong python?

Đưa ra một số nguyên n, chúng ta cần tìm một loạt các số nguyên dương sao cho tất cả các số trong phạm vi đó là tổng hợp và độ dài của phạm vi đó là n. Bạn có thể in bất cứ ai phạm vi trong trường hợp nhiều hơn một câu trả lời. Một số tổng hợp là một số nguyên dương có ít nhất một chia khác với 1 và chính nó (nguồn: wiki) & nbsp;

Show

Ví dụ: & nbsp; 

Input : 3
Output : [122, 124]
Explanation 122, 123, 124 are all composite numbers

Giải pháp là ít khó khăn. Vì có nhiều câu trả lời có thể, chúng tôi thảo luận về một giải pháp tổng quát ở đây. & Nbsp; & nbsp;

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]

Ví dụ cho thuật toán trên & nbsp;

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites

C++

#include <bits/stdc++.h>

using namespace std;

int factorial (int

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
4
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
5

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
1

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

int

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
4int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

int

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
9

int

[122, 124]
1

[122, 124]
2
[122, 124]
3
[122, 124]
4
[122, 124]
5
[122, 124]
6
[122, 124]
7
[122, 124]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 #include <bits/stdc++.h>0

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

int #include <bits/stdc++.h>3

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3int #include <bits/stdc++.h>7

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3#include <bits/stdc++.h>9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 #include <bits/stdc++.h>0

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Java

using4 using5

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3using8 int namespace0int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
4 namespace7namespace8namespace9

std;0

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 std;2
[122, 124]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 std;6std;2std;8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3using8 int3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
4int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

________ 89 ________ 8 & nbsp; factorial (1factorial (2

[122, 124]
factorial (2

________ 89 ________ 8 & nbsp; factorial (8std;2

[122, 124]
8

int9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
02
[122, 124]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
04
[122, 124]
5
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
06
[122, 124]
7std;8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
12 using8 int3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
15
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
16
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
17

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
222
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
23
[122, 124]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6#include <bits/stdc++.h>9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Python3

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
30
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
31

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
33
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34 std;2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
37
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
38
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
39
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
40
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
41__

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
33
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
49
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
51

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
54

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
30
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
56

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
33
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
60
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
44

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
67
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
33
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
44
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
71
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
72 std;2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
75
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
41
[122, 124]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
44
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
79
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
80
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
44
[122, 124]
5
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
44
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
79
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
85
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
44
[122, 124]
7namespace9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
71
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
23

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
92

C#

using

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
94

using4

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
96

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3using8 int namespace0int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
4 namespace7namespace8namespace9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3using8 int3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
4int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

________ 89 ________ 8 & nbsp; factorial (1factorial (2

[122, 124]
factorial (2

________ 89 ________ 8 & nbsp; factorial (8std;2

[122, 124]
8

int9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
02
[122, 124]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
04
[122, 124]
5
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
06
[122, 124]
7std;8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
12 using8 int3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
15
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
16
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
17

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
222
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
23
[122, 124]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
30
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
31

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6#include <bits/stdc++.h>9

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
33
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34 std;2

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]3Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]37 Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]38Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]39 Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]40Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]41__

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
56

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
33
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
49
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
34
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
51

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
54

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
1

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

int

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
4int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

int

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
9

int

[122, 124]
1

[122, 124]
2
[122, 124]
3
[122, 124]
4
[122, 124]
5
[122, 124]
6
[122, 124]
7
[122, 124]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 #include <bits/stdc++.h>0

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

int #include <bits/stdc++.h>3

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
4
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
59std;8

[122, 124]
11

Let the length of range be n and range starts from a then, a, a+1, a+2, ...., a+n-1 all should be composite. So the problem boils down to finding such 'a'. If we closely observe p! (where p is a positive integers) then we will find that, p! has factors of 2, 3, 4, ..., p-1, Hence if we add i to p! such that 1 < i < p, then p! + i has a factor i, so p! + i must be composite. So we end up finding p! + 2, p! + 3, .... p! + p-1 are all composite and continuous integers forming a range [p! + 2, p! + p-1] The above range consists of p-2 elements. For a range of n elements we need to consider (n+2)! If we take a = (n+2)! + 2, Then, a + 1 = (n+2)! + 3 Then, a + 2 = (n+2)! + 4 ... Then, a + n-1 = (n+2)! + n+1 Hence, a = (n+2)! + 2 = 2*3*....*(n+2) + 2 a has 2 as its divisor because (n+2)! and 2 both divides 2 a + 1 = 2*3*....*(n+2) + 3 a + 1 has 3 as its divisor because (n+2)! and 3 both divides 3 ... a + n-1 = 2*3*....*(n+2) + n+1 a + n-1 has n+1 as its divisor because (n+2)! and n+1 both divides n+1 Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]3int #include <bits/stdc++.h>7

[122, 124]
12

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 #include <bits/stdc++.h>0

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
4
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
5

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
6
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
8

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7
n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
1

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

int

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
4int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
2

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
[122, 124]
30

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
[122, 124]
32

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
[122, 124]
34

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
7 #include <bits/stdc++.h>0

n = 3
Then a = (n+2)! + 2
a = 5! + 2
a + 1 = 5! + 3
a + 2 = 5! + 4
Here a is divisible by 2
Here a + 1 is divisible by 3
Here a + 2 is divisible by 4
Hence a, a+1, a+2 are all composites
2

[122, 124]
39

#include <bits/stdc++.h>9

[122, 124]
41

Java 

[122, 124]

using4 using5 
Time Complexity : O(n) 
Auxiliary Space : O(1)

Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
3using8 int namespace0int
Let the length of range be n and range starts 
from a then, a, a+1, a+2, ...., a+n-1 all should 
be composite. So the problem boils down to finding
such 'a'.

If we closely observe p! (where p is a positive 
integers) then we will find that, p! has factors of
2, 3, 4, ..., p-1,
Hence if we add i to p! such that 1 < i < p,
then p! + i has a factor i, so p! + i must be 
composite. So we end up finding p! + 2, p! + 3,
 .... p! + p-1 are all composite and continuous 
integers forming a range [p! + 2, p! + p-1]
The above range consists of p-2 elements.
For a range of n elements we need to consider (n+2)!

If we take a = (n+2)! + 2, 
Then, a + 1 = (n+2)! + 3
Then, a + 2 = (n+2)! + 4
...
Then, a + n-1 = (n+2)! + n+1
Hence,
a = (n+2)! + 2 = 2*3*....*(n+2) + 2
a has 2 as its divisor because (n+2)! and 2 
both divides 2
a + 1 = 2*3*....*(n+2) + 3
a + 1 has 3 as its divisor because (n+2)! 
and 3 both divides 3
...
a + n-1 = 2*3*....*(n+2) + n+1
a + n-1 has n+1 as its divisor because (n+2)! 
and n+1 both divides n+1

Therefore range will be [ (n+2)! + 2, ( (n+2)! + 2 ) + n-1]
1Pratik Chhajer. If you like GeeksforGeeks and would like to contribute, you can also write an article using write.geeksforgeeks.org or mail your article to . See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above.
 


Làm thế nào để bạn tìm thấy một số tổng hợp trong Python?

Cách tiếp cận :..
Đọc số đầu vào bằng đầu vào () hoặc raw_input () ..
Kiểm tra xem Num có lớn hơn 1 ..
Tìm các yếu tố. Chạy A cho vòng lặp từ 2 đến số được nhập. ....
Nếu số được nhập là 0 hoặc 1, chúng tôi nói rằng số không phải là số nguyên tố cũng như số tổng hợp ..
Tất cả các số khác là số tổng hợp ..
In kết quả ..

Công thức của số tổng hợp là gì?

Công thức tạo ra tất cả các số lẻ composite được đưa ra bởi sàng của Marouane. P2N+2pn. C = n trong đó c là hằng số n là tổng hợp lẻ và pn là số nguyên tố ngoại trừ số nguyên tố 2. Đối với pn = 5, chúng ta nhận được 25+10c = n, với c từ 0 đến 5, bạn nhận được số lẻ 25 , 35,45,55,65 ....p2n+2pn. c=N where c is a constant N is an odd composite and pn is a prime number except the prime 2. for pn=5, we get 25+10c=N, for c from 0 to 5, you get the odd numbers 25,35,45,55,65 ....

Làm thế nào để bạn tìm thấy số tổng hợp thứ n?

Làm thế nào để tìm số tổng hợp ?..
Tìm tất cả các yếu tố của số nguyên dương ..
Một số được cho là Prime nếu nó chỉ có hai yếu tố, 1 và chính nó ..
Nếu số có nhiều hơn hai yếu tố, thì đó là một tổng hợp ..

Làm thế nào để bạn tìm thấy phạm vi của một số nguyên tố trong Python?

Bước 1: Vòng lặp qua tất cả các yếu tố trong phạm vi đã cho.Bước 2: Kiểm tra từng số nếu nó có bất kỳ yếu tố nào giữa 1 và chính nó.Bước 3: Nếu có, thì số không phải là số nguyên tố và nó sẽ chuyển sang số tiếp theo.Bước 4: Nếu không, đó là số chính và chương trình sẽ in nó và kiểm tra số tiếp theo.