Research Article

Road Traffic Monitoring System Based on Mobile Devices and Bluetooth Low Energy Beacons

Algorithm 5

Events_update function.
1Input: Events, New_events
2Output: Events
3New_times:= Select time from New_events
4Times:= Select time from Events
5for each t in New_times do
6begin
7event:= Select * from New_events where time = t
8if t is in Times then Delete from Events where time = t
9Insert event into Events
10End