added segment trees