Now print the smallest twin in range
for ( int i = low ; i <= high ; i ++ ) { if ( prime [ i ] && prime [ i + 2 ] ) { cout << " Smallest ▁ twins ▁ in ▁ given ▁ range : ▁ ( " << i << " , ▁ " << i + 2 << " ) " ; twin = true ; break ; } } if ( twin == false ) cout << " No ▁ such ▁ pair ▁ exists " << endl ; }