From 2e811f1e3db0a5038294a250d92db2af380b6759 Mon Sep 17 00:00:00 2001 From: liefooga Date: Tue, 26 Jun 2007 12:21:39 +0000 Subject: [PATCH] update cpp git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@393 331e1502-861f-0410-8da2-ba01fb791d7f --- branches/paradiseo-moeo-1.0/tutorial/Lesson2/Sch1.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/branches/paradiseo-moeo-1.0/tutorial/Lesson2/Sch1.cpp b/branches/paradiseo-moeo-1.0/tutorial/Lesson2/Sch1.cpp index 17469a2aa..562df7bc5 100644 --- a/branches/paradiseo-moeo-1.0/tutorial/Lesson2/Sch1.cpp +++ b/branches/paradiseo-moeo-1.0/tutorial/Lesson2/Sch1.cpp @@ -10,13 +10,12 @@ */ //----------------------------------------------------------------------------- -using namespace std; - #include #include #include #include -#include + +using namespace std; // the moeoObjectiveVectorTraits : minimizing 2 objectives class Sch1ObjectiveVectorTraits : public moeoObjectiveVectorTraits @@ -26,7 +25,7 @@ public: { return true; } - static unsigned nObjectives () + static unsigned int nObjectives () { return 2; } @@ -67,8 +66,8 @@ public: int main (int argc, char *argv[]) { // parameters - unsigned POP_SIZE = 20; - unsigned MAX_GEN = 100; + unsigned int POP_SIZE = 20; + unsigned int MAX_GEN = 100; double M_EPSILON = 0.01; double P_CROSS = 0.25; double P_MUT = 0.35;