Browse Source

Merge remote-tracking branch 'origin/master'

master
Oliver Hofmann 6 months ago
parent
commit
1b50c6e5d9
1 changed files with 12 additions and 0 deletions
  1. 12
    0
      SoSe24/algodat/foundation.py

+ 12
- 0
SoSe24/algodat/foundation.py View File

@@ -23,6 +23,18 @@ class AlgoDatValue:
print(f"Div: {AlgoDatValue.div_operation}")
print(f"Bit: {AlgoDatValue.bit_operation}")

@staticmethod
def reset():
AlgoDatValue.memory = 0
AlgoDatValue.read = 0
AlgoDatValue.write = 0
AlgoDatValue.compare = 0
AlgoDatValue.add_operation = 0
AlgoDatValue.sub_operation = 0
AlgoDatValue.mul_operation = 0
AlgoDatValue.div_operation = 0
AlgoDatValue.bit_operation = 0

def __init__(self, value):
AlgoDatValue.memory += 1
AlgoDatValue.write += 1

Loading…
Cancel
Save