UiB Training 2018: Segment Trees, Max Flow