rstrip()

本文涉及的产品
实时计算 Flink 版,5000CU*H 3个月
检索分析服务 Elasticsearch 版,2核4GB开发者规格 1个月
大数据开发治理平台 DataWorks,不限时长
简介: rstrip()

rstrip():去除字符串右边指定的字符(默认为空格)

string = "   Hello, World!   "
new_string = string.rstrip()
print(new_string)


相关文章
|
15天前
|
C++
大小写转换——islower/isupper或者tolwer/toupper函数的用法
大小写转换——islower/isupper或者tolwer/toupper函数的用法
16 0
|
3月前
strip()
strip()
73 0
|
10月前
1212:LETTERS
1212:LETTERS
|
10月前
|
Python
Python:字符串基操_strip()/rstrip()/lstrip()_lower()/upper()_startswith()/endswith()_split()/rspilt()_join
Python:字符串基操_strip()/rstrip()/lstrip()_lower()/upper()_startswith()/endswith()_split()/rspilt()_join
78 0
|
应用服务中间件 nginx C语言
大小写转换还能这样写?
大小写转换还能这样写?
118 1
大小写转换还能这样写?
Anton and Letters
Anton and Letters
84 0
Anton and Letters
|
Python
strip
1092 0