modified code