I am trying to sort and copy an array using only <algorithm>, but cannot figure out how to accomplish either.  This is the code I have been trying to make work, but with no success.  What am I missing?
sorted_sc_array(const sorted_sc_array& A);          
template< sorted_sc_array& A, sorted_sc_array& T>   
auto Copy(sorted_sc_array& A, sorted_sc_array& T)   
    ->signed char*(T.begin())   
{  
  auto it1=std::begin(A);  
  auto it2=std::begin(T);
  while(it1 != std::end(A)){
    *it2++ = *it1++;
  }
  return it2;
}
 
     
    