Code: Select all
#include <stdio.h>
#include <stdlib.h>
#define MAX_SEARCH 500
int main( void )
{
int num_testing = 0, sum = 0, work = 0;
for( work = 0 ; num_testing <= MAX_SEARCH ; num_testing++ )
{
for( ; sum <= MAX_SEARCH; sum + 2 )
{
if( num_testing % sum )
{
printf( "%d, ", num_testing );
break;
}
for( ; sum <= MAX_SEARCH; sum + 3 )
{
if( num_testing % sum )
{
printf( "%d, ", num_testing );
break;
}
for( ; sum <= MAX_SEARCH; sum + 6 )
{
if( num_testing % sum )
{
printf( "%d, ", num_testing );
break;
}
for( ; sum <= MAX_SEARCH; sum + 7 )
{
if( num_testing % sum )
{
printf( "%d, ", num_testing );
break;
}
}
}
}
}
}
puts("DONE!");
system("pause");
return 0;
}