tables::column::except

template <is_primitive_type P>
column<P> column<P>::except(const column<P>& col) const

Return column with same items excluding items that are in col.

Complexity

Same as std::sort

Example

Code

#include <cpptables/table.hh>

using namespace tables;
using namespace std;

void column_except()
{
  const column<unsigned> xs ({ 1, 2, 3, 4, 5});

  const column<unsigned> ys ({ 2, 3});
  const column<unsigned> zs = xs.except(ys);
  cout << zs << "\n";
}

Output

1 4 5