Advertisement
zelekkartofelek

main

Nov 15th, 2019
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.46 KB | None | 0 0
  1. #include<iostream>
  2. #include "list.h"
  3. #include "funkcje.h"
  4. using namespace std;
  5. int main() {
  6.     List vertices;
  7.     if(!wczytaj("grafy.txt", vertices)) return 0;
  8.     List red, blue;
  9.     List checked;
  10.     int first = vertices.get(0);
  11.     color_vertex(first, vertices, red, blue, 0, checked);
  12.     for (int i = 0; i < red.size(); i++) {
  13.         cout << red.get(i) << "  ";
  14.     }
  15.     std::cout << endl;
  16.     for (int i = 0; i < blue.size(); i++) {
  17.         cout << blue.get(i) << "  ";
  18.     }
  19.     return 0;
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement