From 0e5e01b4d0d5f3f872d97c95bd57fd057e4fd5a1 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Thu, 9 May 2013 15:44:34 -0600 Subject: Added Number::toRadix & Number::set( int32_t ). Both very handy. I'll add other numeric setters later, it was very easy. --- src/options.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/options.cpp') diff --git a/src/options.cpp b/src/options.cpp index d9cd8f1..59dd2b4 100644 --- a/src/options.cpp +++ b/src/options.cpp @@ -19,7 +19,8 @@ Options::Options( int argc, char *argv[] ) : addOption( Bu::slot(this, &Options::textPrimes), "text-primes", "Generate primes in base 36 that only have digits > 9 in them."); addOption( Bu::slot(this, &Options::isPrime), 'p', "is-prime", - "Test if the given number is prime. Set radix first."); + "Tests every parameter after to see if it is prime then prints out " + "the ones that are prime. Set radix first."); addHelpOption('h', "help", "This help"); parse( argc, argv ); @@ -93,12 +94,9 @@ int Options::isPrime( Bu::StringArray aArgs ) one = "1"; fact = "2"; - Bu::println("Radix: %1").arg( iRadix ); - for( Bu::StringArray::iterator i = aArgs.begin()+1; i; i++ ) { tst = *i; - Bu::println("%1").arg( tst ); max = tst / fact; bool bPrime = true; for( j = "2"; j < max; j = j + one ) -- cgit v1.2.3