Submission #1239801


Source Code Expand

# include <iostream> 
# include <vector>
# include <limits>
# include <algorithm>
# include <map>
# include <string>
# include <functional>
# include <cmath>
# include <iomanip>
using namespace std;
 
int main() {
	string a, b, c;
	cin >> a >> b >> c;
	transform(a.begin(), a.end(), a.begin(), toupper);
	transform(b.begin(), b.end(), b.begin(), toupper);
	transform(c.begin(), c.end(), c.begin(), toupper);
	cout << a[0] <<b[0] << c[0] << endl;
}

Submission Info

Submission Time
Task A - Three-letter acronym
User M3_cp
Language C++14 (GCC 5.4.1)
Score 0
Code Size 465 Byte
Status CE

Compile Error

./Main.cpp: In function ‘int main()’:
./Main.cpp:15:50: error: no matching function for call to ‘transform(std::basic_string<char>::iterator, std::basic_string<char>::iterator, std::basic_string<char>::iterator, <unresolved overloaded function type>)’
  transform(a.begin(), a.end(), a.begin(), toupper);
                                                  ^
In file included from /usr/include/c++/5/algorithm:62:0,
                 from ./Main.cpp:4:
/usr/include/c++/5/bits/stl_algo.h:4164:5: note: candidate: template<class _IIter, class _OIter, class _UnaryOperation> _OIter std::transform(_IIter, _IIter, _OIter, _UnaryOperation)
     transform(_InputIterator __first, _InputIterator __last,
     ^
/usr/include/c++/5/bits/stl_algo.h:4164:5: note:   template argument deduction/substitution failed:
./Main.cpp:15:50: note:   couldn't deduce template parameter ‘_UnaryOperation’
  transform(a.begin(), a.end(), a.begin(), toupper);
                                                  ^
In file included from /usr/include/c...