C++17 standartlarına göre aşağıdaki C++ programı çalıştırıldığında bu programın çıktısı ne olur?
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
#include <algorithm> #include <iostream> #include <string> int main() { std::string s1{ "AA" }; std::string s2{ "AA" }; const auto &smax{ std::max(s1, s2) }; const auto &smin{ std::min(s1, s2) }; s1 += "A"; s2 += "B"; std::cout << smax << smin; } |
Sorunun yanıtı şu seçeneklerden biri de olabilir: Sentaks hatası (derleme zamanı