int main() { Graf g; int n = 9, m = 12; int v[] = {1, 1, 2, 2, 3, 4, 4, 5, 5, 6, 7, 8}; int w[] = {2, 4, 3, 5, 6, 5, 7, 6, 8, 9, 8, 9}; initG(g, n); build(g, m, v, w); printf("Vecini:\n"); show(g); printf("Vertex Cover:\n5 1 3 7 9\n"); return 0; }
void readG (Graph &g) { int n; scanf("%d", &n); initG(g, n); int v, w, cost; while (1) { scanf("%d", &v); if (v == 0) break; scanf("%d %d", &w, &cost); addArc(g, v, w, cost); } }
int criaG(char *fileName) { initG(); logAnAutArtTIT(); anoAutoresArtigo(); logAutoresArtigoTIT(); nAutoresArtigo(); readIntervalos("datas3.txt"); // logIntervaloTIT(); // AQUI EM VEZ DISTO TEM DE CHAMAR A QUE LE O TXT // intervalosAnos(anoInicial, anoFinal); // CORRIGIR //logAnosAutoresPercentagemTIT(); //AQUI EM VEZ DISTO TEM DE CHAMAR A QUE LE O TXT readAno("datas4.txt"); closeG(); return 0; }
int main(int argc, char **argv) { initWindow(); initInputs(); initG(); #ifdef __APPLE__ glfwInit(); #else glewInit(); #endif initShaders(); world.loadSpheres(); world.load("obj/island.obj", 0, 0, 0, 1.0); world.load("obj/box.obj", 0, 0, 0, 0.6); world.skybox.load("skyboxes/bluesky1"); world.sea.load(WINDOW_RESOLUTION_X, WINDOW_RESOLUTION_Y); world.loadMusic(); mainLoop(); exit(EXIT_FAILURE); }