mirror of https://github.com/xfarrow/lasd.git
parent
c32e658308
commit
2e4f7c3de8
|
@ -142,7 +142,11 @@ BinaryTreeLnk<Data>& BinaryTreeLnk<Data>::operator=(BinaryTreeLnk<Data>&& tree)
|
|||
|
||||
template <typename Data>
|
||||
bool BinaryTreeLnk<Data>::operator==(const BinaryTreeLnk<Data>& tree) const noexcept{
|
||||
if(size == tree.size){
|
||||
return (Root() == tree.Root());
|
||||
}else{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
template <typename Data>
|
||||
|
|
|
@ -105,6 +105,7 @@ BinaryTreeVec<Data>::~BinaryTreeVec(){
|
|||
|
||||
template <typename Data>
|
||||
BinaryTreeVec<Data>& BinaryTreeVec<Data>::operator=(const BinaryTreeVec<Data>& bt){
|
||||
Clear();
|
||||
size = bt.size;
|
||||
tree.Resize(size);
|
||||
for(ulong i=0 ; i<size ; ++i){
|
||||
|
@ -116,6 +117,7 @@ BinaryTreeVec<Data>& BinaryTreeVec<Data>::operator=(const BinaryTreeVec<Data>& b
|
|||
|
||||
template <typename Data>
|
||||
BinaryTreeVec<Data>& BinaryTreeVec<Data>::operator=(BinaryTreeVec<Data>&& bt) noexcept{
|
||||
Clear();
|
||||
std::swap(size, bt.size);
|
||||
std::swap(tree, bt.tree);
|
||||
for(ulong i=0 ; i<size ; ++i){
|
||||
|
|
|
@ -15,10 +15,10 @@ using namespace std;
|
|||
|
||||
void lasdtest() {
|
||||
cout << endl << "~*~#~*~ Welcome to the LASD Test Suite ~*~#~*~ " << endl;
|
||||
//testSimpleExercise1();
|
||||
//testFullExercise1();
|
||||
//testSimpleExercise2();
|
||||
//testFullExercise2();
|
||||
testSimpleExercise1();
|
||||
testFullExercise1();
|
||||
testSimpleExercise2();
|
||||
testFullExercise2();
|
||||
testSimpleExercise3();
|
||||
testFullExercise3();
|
||||
cout << endl << "Goodbye!" << endl;
|
||||
|
|
Loading…
Reference in New Issue