Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ArrayList lista(10);
- lista.append(1);
- lista.append(2);
- lista.append(5);
- lista.append(7);
- lista.append(8);
- lista.append(9);
- lista.append(2);
- lista.append(11);
- lista.append(12);
- lista.append(12);
- cout << lista << endl;
- lista.del(lista.last());
- if(lista.empty())
- cout << "empty" << endl;
- if(lista.full())
- cout << "full" << endl;
- cout << lista << endl;
- lista.del(5);
- cout << lista << endl;
- cout << lista.prev(3) << endl;
- cout << lista.locate(4) << endl;
- lista.insert(5, 5);
- cout << lista << endl;
- lista.del(5);
- cout << lista << endl;
- lista.clear();
- if(lista.empty())
- cout << "empty" << endl;
- if(lista.full())
- cout << "full" << endl;
- cout << lista << endl;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement