SHIFT =LEFT will left-squeeze by removing all of the blanks, shifting the remaining characters to the left and padding on…