Language: C++

#include<iostream>
#include<algorithm>
#include<tuple>
using namespace std;
tuple<int,int,char,long long,string>a[1<<17];
main()
{
    int n;cin>>n;
    for(int i=0;i<n;i++)
    {
        int A,b;char c;long long d;string e;
        cin>>A>>b>>c>>d>>e;
        a[i]=make_tuple(A,b,c,d,e);
    }
    sort(a,a+n);
    for(int i=0;i<n;i++)
    {
        cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
    }
}


Compiler output:
a.cc:6:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    6 | main()
      | ^~~~
a.cc: In function 'int main()':
a.cc:18:22: error: expected ')' before 'a'
   18 |         cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
      |               ~      ^
      |                      )
In file included from /usr/include/c++/14/bits/memory_resource.h:47,
                 from /usr/include/c++/14/string:68,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/tuple: In instantiation of 'struct std::tuple_element<0, std::tuple<> >':
/usr/include/c++/14/bits/utility.h:84:11:   required by substitution of 'template<long unsigned int __i, class _Tp> using std::__tuple_element_t = typename std::tuple_element::type [with long unsigned int __i = 0; _Tp = std::tuple<>]'
   84 |     using __tuple_element_t = typename tuple_element<__i, _Tp>::type;
      |           ^~~~~~~~~~~~~~~~~
/usr/include/c++/14/tuple:2466:5:   required by substitution of 'template<class _Ostream, class _Tp> _Ostream&& std::operator<<(_Ostream&&, const _Tp&) [with _Ostream = std::basic_ostream<char>&; _Tp = <missing>]'
 2466 |     get(const tuple<_Elements...>&& __t) noexcept
      |     ^~~
a.cc:18:105:   required from here
   18 |         cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
      |                                                                                                         ^~~~
/usr/include/c++/14/tuple:2422:25: error: static assertion failed: tuple index must be in range
 2422 |       static_assert(__i < sizeof...(_Types), "tuple index must be in range");
      |                     ~~~~^~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/tuple:2422:25: note: the comparison reduces to '(0 < 0)'
In file included from /usr/include/c++/14/bits/stl_pair.h:62,
                 from /usr/include/c++/14/bits/stl_algobase.h:64,
                 from /usr/include/c++/14/string:51:
/usr/include/c++/14/bits/utility.h: In instantiation of 'struct std::_Nth_type<0>':
/usr/include/c++/14/tuple:2424:13:   required from 'struct std::tuple_element<0, std::tuple<> >'
 2424 |       using type = typename _Nth_type<__i, _Types...>::type;
      |             ^~~~
/usr/include/c++/14/bits/utility.h:84:11:   required by substitution of 'template<long unsigned int __i, class _Tp> using std::__tuple_element_t = typename std::tuple_element::type [with long unsigned int __i = 0; _Tp = std::tuple<>]'
   84 |     using __tuple_element_t = typename tuple_element<__i, _Tp>::type;
      |           ^~~~~~~~~~~~~~~~~
/usr/include/c++/14/tuple:2466:5:   required by substitution of 'template<class _Ostream, class _Tp> _Ostream&& std::operator<<(_Ostream&&, const _Tp&) [with _Ostream = std::basic_ostream<char>&; _Tp = <missing>]'
 2466 |     get(const tuple<_Elements...>&& __t) noexcept
      |     ^~~
a.cc:18:105:   required from here
   18 |         cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
      |                                                                                                         ^~~~
/usr/include/c++/14/bits/utility.h:237:13: error: '__type_pack_element' index is out of range
  237 |     { using type = __type_pack_element<_Np, _Types...>; };
      |             ^~~~
a.cc:18:105: error: use of deleted function 'constexpr std::__enable_if_t<(__i >= sizeof... (_Types))> std::get(const tuple<_Elements ...>&) [with long unsigned int __i = 0; _Elements = {}; __enable_if_t<(__i >= sizeof... (_Types))> = void]'
   18 |         cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
      |                                                                                                         ^~~~
/usr/include/c++/14/tuple:2476:5: note: declared here
 2476 |     get(const tuple<_Elements...>&) = delete;
      |     ^~~
a.cc:18:105: error: use of deleted function 'constexpr std::__enable_if_t<(__i >= sizeof... (_Types))> std::get(const tuple<_Elements ...>&) [with long unsigned int __i = 0; _Elements = {}; __enable_if_t<(__i >= sizeof... (_Types))> = void]'
   18 |         cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
      |                                                                                                         ^~~~
/usr/include/c++/14/tuple:2476:5: note: declared here
 2476 |     get(const tuple<_Elements...>&) = delete;
      |     ^~~
a.cc:18:105: error: use of deleted function 'constexpr std::__enable_if_t<(__i >= sizeof... (_Types))> std::get(const tuple<_Elements ...>&) [with long unsigned int __i = 0; _Elements = {}; __enable_if_t<(__i >= sizeof... (_Types))> = void]'
   18 |         cout<<(get<0>a[i])<<" "<<(get<1>a[i])<<" "<<(get<2>a[i])<<" "<<(get<3>a[i])<<" "<<(get<4>a[i])<<endl;
      |                                                                                                         ^~~~
/usr/include/c++/14/tuple:2476:5: note: declared here
 2476 |     get(const tuple<_Elements...>&) = delete;
      |     ^~~