From 5e6b2719c7dddeba15814d8bb2c9ab1f1f11ff77 Mon Sep 17 00:00:00 2001 From: tiennm99 Date: Sat, 29 Nov 2025 00:09:55 +0700 Subject: [PATCH] feat(cpp): add thtbangc2025_bai1 --- cpp/thtbangc2025_bai1.cpp | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 cpp/thtbangc2025_bai1.cpp diff --git a/cpp/thtbangc2025_bai1.cpp b/cpp/thtbangc2025_bai1.cpp new file mode 100644 index 0000000..1289dcf --- /dev/null +++ b/cpp/thtbangc2025_bai1.cpp @@ -0,0 +1,25 @@ +#include +using namespace std; + +int main() { + ios::sync_with_stdio(false); + cin.tie(nullptr); + + int N; + cin >> N; + map count; + for (int i = 0; i < 2 * N - 1; ++i) { + string s; + cin >> s; + count[s]++; + } + + for (auto &p: count) { + if (p.second % 2 == 1) { + cout << p.first << "\n"; + break; + } + } + + return 0; +}