Remove unnecessary variable and shorten the notation