Genetic algorithms in cpp | SoloLearn: Learn to code for FREE!

+9

Genetic algorithms in cpp

How can describe this to me ??I will give a present But remember that u should have understandable examples too

1/24/2020 11:25:13 AM

bye

7 Answers

New Answer

+4

A genetic algorithm eh? My favorite! I don't use cpp though. I use Python for this, but any turing complete language can do this. First you must decide on a task that's fast to run and easy to score. How about printing hello world! Then you generate a large list of other lists containing letters. We'll call these creatures. You test each creature to see how close it is to "hello world", assigning a score. Then we take the top preformers, and overwrite (aka killing the underpreforming creatures, and birthing copies of the best), with some minor random letter changes with each birth. Repeat! Assuming you coded it right, the creatures will evolve into hello world. Congrats, that is a very simple genetic algorithm. You can go a lot farther with it via more complex tasks, parent breeding, genetic programming, tournament selection, and so much more! GL!

+6

This documentation might be helpful to you: http://www.icce.rug.nl/documents/cplusplus/cplusplus19.html

+6

Vinay_GB Tnx too https://soundcloud.com/nocopyrightsounds/debris-rudelies-animal-ft-jex-ncs-release Listen this a the present

+5

Ahri Fox Yeah !! Tnx for that

+4

Hardik Pandya 👍👍👍👍👍🙌🙌

+4

Hardik Pandya Ok https://soundcloud.com/nocopyrightsounds/debris-rudelies-animal-ft-jex-ncs-release

+1

This video helped me a lot at my first genetic programming steps. https://www.youtube.com/watch?v=9kbzMeEBvUY You can do it in every programming language by using simple lists.