Added my changes of the original code