Submission #3443067


Source Code Expand

#include <bits/stdc++.h>

using namespace std;

using ll = long long;

int main() {
    cin.tie(0); ios::sync_with_stdio(false);

    string n;
    cin >> n;
    if (n[0] == n[1]) cout < "Yes\n";
    else cout << "No\n";

    return 0;
}

Submission Info

Submission Time
Task A - Palindromic Number
User pqwmL769
Language C++14 (GCC 5.4.1)
Score 0
Code Size 254 Byte
Status CE

Compile Error

./Main.cpp: In function ‘int main()’:
./Main.cpp:12:28: error: no match for ‘operator<’ (operand types are ‘std::ostream {aka std::basic_ostream<char>}’ and ‘const char [5]’)
     if (n[0] == n[1]) cout < "Yes\n";
                            ^
In file included from /usr/include/c++/5/regex:61:0,
                 from /usr/include/x86_64-linux-gnu/c++/5/bits/stdc++.h:108,
                 from ./Main.cpp:1:
/usr/include/c++/5/bits/regex.h:1426:5: note: candidate: template<class _Bi_iter> bool std::operator<(const std::sub_match<_BiIter>&, const typename std::iterator_traits<_Iter>::value_type&)
     operator<(const sub_match<_Bi_iter>& __lhs,
     ^
/usr/include/c++/5/bits/regex.h:1426:5: note:   template argument deduction/substitution failed:
./Main.cpp:12:30: note:   ‘std::ostream {aka std::basic_ostream<char>}’ is not derived from ‘const std::sub_match<_BiIter>’
     if (n[0] == n[1]) cout < "Yes\n";
                              ^
In file included from /usr/include/c++/5/regex:61:0,
                 fro...