C ++ program to find number of prime numbers in a subarray and performing updates
#include <bits/stdc++.h> NEW_LINE using namespace std ; #define MAX  1000 NEW_LINE void sieveOfEratosthenes ( bool isPrime [ ] ) { isPrime [ 1 ] = false ; for ( int p = 2 ; p * p <= MAX ; p ++ ) {