Remove general problem and solution from generator object

This commit is contained in:
lukew3
2021-10-02 23:52:10 -04:00
parent a6dbd2cf9f
commit 6b35cbb452
114 changed files with 78 additions and 186 deletions

View File

@@ -21,6 +21,5 @@ def BCDtoDecimalFunc(maxNumber=10000):
bcd_to_decimal = Generator("Binary Coded Decimal to Integer", 91,
"Integer of Binary Coded Decimal b is ", "n",
BCDtoDecimalFunc,
["maxNumber=10000"])

View File

@@ -29,6 +29,5 @@ def binary2sComplementFunc(maxDigits=10):
binary_2s_complement = Generator("Binary 2's Complement", 73,
"2's complement of 11010110 =", "101010",
binary2sComplementFunc,
["maxDigits=10"])

View File

@@ -15,6 +15,6 @@ def binaryComplement1sFunc(maxDigits=10):
return problem, solution
binary_complement_1s = Generator("Binary Complement 1s", 4, "1010=", "0101",
binary_complement_1s = Generator("Binary Complement 1s", 4,
binaryComplement1sFunc,
["maxDigits=10"])

View File

@@ -12,6 +12,6 @@ def binaryToDecimalFunc(max_dig=10):
return problem, solution
binary_to_decimal = Generator("Binary to Decimal", 15, "Decimal of a=", "b",
binary_to_decimal = Generator("Binary to Decimal", 15,
binaryToDecimalFunc,
["max_dig=10"])

View File

@@ -11,6 +11,5 @@ def binaryToHexFunc(max_dig=10):
return problem, solution
binary_to_hex = Generator("Binary to Hexidecimal", 64, "Hexidecimal of a=",
"b", binaryToHexFunc,
binary_to_hex = Generator("Binary to Hexidecimal", 64, binaryToHexFunc,
["max_dig=10"])

View File

@@ -17,6 +17,5 @@ def DecimalToBCDFunc(maxNumber=10000):
decimal_to_bcd = Generator("Decimal to Binary Coded Decimal", 103,
"Binary Coded Decimal of Decimal n is ", "b",
DecimalToBCDFunc,
["maxNumber=10000"])

View File

@@ -11,6 +11,6 @@ def DecimalToBinaryFunc(max_dec=99):
return problem, solution
decimal_to_binary = Generator("Decimal to Binary", 14, "Binary of a=", "b",
decimal_to_binary = Generator("Decimal to Binary", 14,
DecimalToBinaryFunc,
["max_dec=99"])

View File

@@ -10,6 +10,5 @@ def deciToHexaFunc(max_dec=1000):
return problem, solution
decimal_to_hexadeci = Generator("Decimal to Hexadecimal", 79, "Binary of a=",
"b", deciToHexaFunc,
decimal_to_hexadeci = Generator("Decimal to Hexadecimal", 79, deciToHexaFunc,
["max_dec=1000"])

View File

@@ -9,6 +9,5 @@ def decimalToOctalFunc(maxDecimal=4096):
decimal_to_octal = Generator("Converts decimal to octal", 84,
"What's the octal representation of 98?", "0o142",
decimalToOctalFunc,
["maxDecimal=4096"])

View File

@@ -22,6 +22,5 @@ def fibonacciSeriesFunc(minNo=1):
fibonacci_series = Generator(
"Fibonacci Series", 56, "fibonacci series of first a numbers",
"prints the fibonacci series starting from 0 to a", fibonacciSeriesFunc,
"Fibonacci Series", 56, fibonacciSeriesFunc,
["minNo=1"])

View File

@@ -11,5 +11,5 @@ def moduloFunc(maxRes=99, maxModulo=99):
return problem, solution
modulo_division = Generator("Modulo Division", 5, "a%b=", "c", moduloFunc,
modulo_division = Generator("Modulo Division", 5, moduloFunc,
["maxRes=99", "maxModulo=99"])

View File

@@ -13,6 +13,5 @@ def nthFibonacciNumberFunc(maxN=100):
nth_fibonacci_number = Generator("nth Fibonacci number", 62,
"What is the nth Fibonacci number", "Fn",
nthFibonacciNumberFunc,
["maxN=100"])