ens-ulm-1

google hashcode 2014 source for team ens-ulm-1
git clone https://a3nm.net/git/ens-ulm-1/
Log | Files | Refs

commit 3ca2b376a74ffcaa0f2e8310c84d3c6c2232f15b
parent 63b3e263110a19ec69e6c8ad6e9fb2af5c382fe8
Author: Jachiet Louis <louis@jachiet.com>
Date:   Sat,  5 Apr 2014 13:17:14 +0200

constantes de mc/lectures.cpp

Diffstat:
contest/louis/louis.cpp | 12++++--------
1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/contest/louis/louis.cpp b/contest/louis/louis.cpp @@ -7,13 +7,9 @@ using namespace std; -const int nbVoitures = 8 ; -const int nbSommets = 11348 ; -const int nbArcs = 17958 ; -const int nbSecondes = 54000 ; const int INF = 1000 * 1000 * 100 ; -short use[nbSommets][nbSommets] ; -int cur_dist[nbSommets] ; +short use[N_SOMMETS_MAJ][N_SOMMETS_MAJ] ; +int cur_dist[N_SOMMETS_MAJ] ; int init ; // Renvoie la première intersection à utiliser @@ -22,11 +18,11 @@ int go_to( int depart, int arrivee) if(!init) { init = 1 ; - fill(use[0],use[nbSommets],-1); + fill(use[0],use[N_SOMMETS_MAJ],-1); } if(use[depart][depart] == -1) return use[depart][arrivee] ; - fill(cur_dist,cur_dist+nbSommets,INF); + fill(cur_dist,cur_dist+N_SOMMETS_MAJ,INF); priority_queue<pair<int,int> > todo ; use[depart][depart] = depart ; todo.push(make_pair(0,depart));