Revert "MISC: HammingCodingContracts need rework"

This commit is contained in:
hydroflame 2022-04-18 12:01:10 -04:00 committed by GitHub
parent 0d7276b76f
commit b49b5ba269
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,7 +1,7 @@
import { getRandomInt } from "../utils/helpers/getRandomInt";
import { MinHeap } from "../utils/Heap";
// import { HammingEncode, HammingDecode } from "../utils/HammingCodeTools";
import { HammingEncode, HammingDecode } from "../utils/HammingCodeTools";
/* tslint:disable:completed-docs no-magic-numbers arrow-return-shorthand */
/* Function that generates a valid 'data' for a contract type */
@ -1247,7 +1247,7 @@ export const codingContractTypesMetadata: ICodingContractTypeMetadata[] = [
return true;
},
} /*
},
{
name: "HammingCodes: Integer to encoded Binary",
numTries: 10,
@ -1305,5 +1305,5 @@ export const codingContractTypesMetadata: ICodingContractTypeMetadata[] = [
solver: (data: string, ans: string): boolean => {
return parseInt(ans, 10) === HammingDecode(data);
},
},*/,
},
];