The Railroad Crossing Problem: Towards Semantics of Timed Algorithms and Their Model Checking in High Level Languages