-
-
Save amankharwal/2a33de4353facf4226ee74b6ba0549c6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import random | |
def generateParents(size): | |
parents = np.array(random.randint(0, 2**size - 1)) | |
for i in range(1, population): | |
parents = np.append(parents, random.randint(0, 2**size - 1)) | |
return parents |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment