there are three string methods that you can use to remove whitespace from string rstrip( lstrip( strip(rstrip(removes whitespace from the right side of stringname "jean-luc picard name 'jean-luc picard name rstrip('jean-luc picardin this examplethe string "jean-luc picard has five trailing spaces you use rstrip(to remove trailing spaces from the right-hand side of the string this returns the new string "jean-luc picard"which no longer has the spaces at the end lstrip(works just like rstrip()except that it removes whitespace from the left-hand side of the stringname jean-luc picardname jean-luc picardname lstrip('jean-luc picardto remove whitespace from both the left and the right sides of the string at the same timeuse strip()name jean-luc picard name jean-luc picard name strip('jean-luc picard