For number of transactions to be n
- Creating set for transactions = O(nlogn)
- For getting valid transaction and appending it in block = O(n2)
- Overall time complexity of solution = O(n2)
- Language: C++
- Code file: code.cpp
- Output file: block.txt
- Dataset: mempool.csv
- Total number of transactions read: 5214
- Number of tx in final block 3174
- Total fee in final block : 5696031
- Total weight of final block: 3999936.00000
- Percentage of weight: 99.99840 %
- Time taken by program is : 1.53348 sec