Knapsack Problem The 0/1 Knapsack problem was solved using genetic algorithm in python. Global variables was changed according to the datasets. The global variables in program are
MAX_WEIGHT Maximum weight the knapsack bag can hold
POPULATION_SIZE Population size of a generation
NUMBER_OF_ITEMS Total number of items available
MUTATION_PROBALITY The probabilty that the child will be mutated
NUMBER_OF_ITERATIONS Total no of generations
The Number of crossovers that happen in a generation is set to POPULATION_SIZE/2 + 1