Added tests
Added performance test to Main
Added comments to Memory