use vanilla python for list manipulation