MCPcopy Create free account
hub / github.com/TheAlgorithms/Python / main

Function main

boolean_algebra/quine_mc_cluskey.py:139–156  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

137
138
139def main() -> None:
140 no_of_variable = int(input("Enter the no. of variables\n"))
141 minterms = [
142 float(x)
143 for x in input(
144 "Enter the decimal representation of Minterms 'Spaces Separated'\n"
145 ).split()
146 ]
147 binary = decimal_to_binary(no_of_variable, minterms)
148
149 prime_implicants = check(binary)
150 print("Prime Implicants are:")
151 print(prime_implicants)
152 chart = prime_implicant_chart(prime_implicants, binary)
153
154 essential_prime_implicants = selection(chart, prime_implicants)
155 print("Essential Prime Implicants are:")
156 print(essential_prime_implicants)
157
158
159if __name__ == "__main__":

Callers 1

Calls 5

decimal_to_binaryFunction · 0.85
prime_implicant_chartFunction · 0.85
selectionFunction · 0.85
splitMethod · 0.80
checkFunction · 0.70

Tested by

no test coverage detected