Create trim

The trim() function deletes all the trailing blanks, but if the length of the 
variable is specified to be more than the actual size of the variable then it trims only till the size specified in the length statement.