git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@519 331e1502-861f-0410-8da2-ba01fb791d7f
21 lines
329 B
C++
21 lines
329 B
C++
// "route.cpp"
|
|
|
|
// (c) OPAC Team, LIFL, January 2006
|
|
|
|
/*
|
|
Contact: paradiseo-help@lists.gforge.inria.fr
|
|
*/
|
|
|
|
#include "route.h"
|
|
|
|
unsigned length (const Route & __route) {
|
|
|
|
unsigned len = 0 ;
|
|
|
|
for (unsigned i = 0; i < numNodes; i ++)
|
|
len += distance (__route [i], __route [(i + 1) % numNodes]) ;
|
|
|
|
return len;
|
|
}
|
|
|
|
|