diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/uci.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/uci.cpp b/src/uci.cpp index 6d2f652..0805c6c 100644 --- a/src/uci.cpp +++ b/src/uci.cpp @@ -306,10 +306,11 @@ void Uci() { auto ms = std::chrono::duration_cast<std::chrono::milliseconds>(end - start) .count(); - std::cout << ms << " ms\n"; - cout << count << "\n"; + std::ostringstream oss; + oss << "{\"ms\": " << ms << ", \"result\": " << count << "}"; + std::string json = oss.str(); - cout.flush(); + std::cout << json << std::endl; } } } |
