Database that works with pairs (date, event).
- Add date event — add a pair(date, event) to the database;
- Print — show all database contents;
- Find condition - show all records contained in the database that satisfy the condition;
- Del condition - remove from the database all records that satisfy the condition;
- Last date - display a record with the latest event that happened not later than the date;
Implemented comparison operators: <, <=, >=, >, ==, !=.
A condition may consist of several sub-conditions that are connected by logical OR / AND.
Find date < 2017-11-06- find all the events that happened before November 6, 2017 and show them;Del event != "holiday"- remove from the database all events except "holiday".Find date >= 2017-01-01 AND date < 2017-07-01 AND event == "sport event"- find all the events "sport event" that occurred in the first half of 2017;Del date < 2017-01-01 AND (event == "holiday" OR event == "sport event")- remove from the database all the events "holiday" and "sport event" that happened before 2017.