implemented train