Changeset 703:32f280a5ed7d in lemon-0.x for src/work/deba/main.cpp
- Timestamp:
- 07/15/04 14:15:58 (20 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@954
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/work/deba/main.cpp
r702 r703 1 // -*- c++ -*- 1 2 #include <iostream> 2 3 #include <cstdlib> … … 5 6 using namespace std; 6 7 using namespace hugo; 8 7 9 8 10 … … 23 25 for (pit = map.begin(); pit != map.end(); ++pit) { 24 26 cout << g.id(pit->first) << ' ' << pit->second << endl; 25 } 26 /* 27 ListGraph::NodeMap<double> ot_map = map; 28 for (ListGraph::NodeIt it(g); g.valid(it); g.next(it)) { 29 ot_map[it] *= 2.1; 30 cout << ot_map[it] << endl; 31 } 32 ot_map = map; 33 for (ListGraph::NodeIt it(g); g.valid(it); g.next(it)) { 34 ot_map[it] *= 3.1; 35 cout << ot_map[it] << endl; 36 }*/ 27 (*pit).second = g.id(pit->first); 28 cout << g.id((*pit).first) << ' ' << (*pit).second << endl; 29 } 30 const ListGraph::NodeMap<int> const_map = map; 31 ListGraph::NodeMap<int>::const_iterator cit; 32 for (cit = const_map.begin(); cit != const_map.end(); ++cit) { 33 cerr << g.id(cit->first) << ' ' << cit->second << endl; 34 cerr << g.id((*cit).first) << ' ' << (*cit).second << endl; 35 } 37 36 return 0; 38 37 }
Note: See TracChangeset
for help on using the changeset viewer.