python去掉空格常用方式
前言:处理字符串时经常要定制化去掉无用的空格,python 中要么用存在的常规方法,或者用正则处理1.去掉左边空格string = " * it is blank space test * "print (string.lstrip())result:* it is blank space test * 2.去掉右边空格string = " * it is blank ...