#define tassert(ex) {if ((ex)) cerr << #ex << "\n"; \
else _assert(#ex, __FILE__,__LINE__); }
while (!a
.empty() && k
++ < maxprint
)
while (!a
.empty()) a
.del_front();
for (int i
= 0; i
< SIZE
; ++i
)
assert(q
.length() == SIZE
);
for (i
= 0; i
< SIZE
; ++i
)
assert(q1
.length() == SIZE
);
assert(q2
.length() == SIZE
);
assert(q1
.length() == SIZE
);
assert(q1
.length() == (SIZE
-1));
cout
<< "q1:"; print(q1
);
for (int i
= 0; i
< SIZE
; ++i
)
assert(q
.length() == SIZE
);
for (i
= 0; i
< SIZE
; ++i
)
assert(q1
.length() == SIZE
);
assert(q2
.length() == SIZE
);
assert(q1
.length() == SIZE
);
assert(q1
.length() == (SIZE
-1));
cout
<< "q1:"; print(q1
);
for (int i
= 0; i
< SIZE
; ++i
)
assert(q
.length() == SIZE
);
for (i
= 0; i
< SIZE
; ++i
)
assert(q1
.length() == SIZE
);
assert(q2
.length() == SIZE
);
assert(q1
.length() == SIZE
);
assert(q1
.length() == (SIZE
-1));
cout
<< "q1:"; print(q1
);
main(int argv
, char** argc
)
SIZE
= abs(atoi(argc
[1]));
cout
<< "XP queues:\n"; XPtest();
if (ptimes
) cout
<< "\ntime = " << return_elapsed_time(0.0) << "\n";
cout
<< "V queues:\n"; Vtest();
if (ptimes
) cout
<< "\ntime = " << return_elapsed_time(0.0) << "\n";
cout
<< "SL queues:\n"; SLtest();
if (ptimes
) cout
<< "\ntime = " << return_elapsed_time(0.0) << "\n";
cout
<< "\nEnd of test\n";