#include #include #include "NameGame.h" constexpr int group_size = 1000, T = 1000; constexpr int cmsize_min = 250, cmsize_max = 255; constexpr int trials = 10; int main(int argc, char* argv[]) { tp::NameGame namegame(group_size, 0, 12); std::vector> runs; for (int i = cmsize_min; i <= cmsize_max; ++i) { for (int j = 0; j < trials; ++j) { namegame.setCMsize(i); namegame.initMemory(); namegame.clearRecord(); int a = namegame.run(group_size * T); runs.push_back({i, a}); } std::cout << "finished cmsize " << i << std::endl; } std::ofstream f("many.csv"); f << "cmsize,adopters\n"; for (const auto& p : runs) { f << p.first << ',' << p.second << '\n'; } return 0; }