替换空格(python)

GitHub:https://github.com/cytues/sword 源码python 题目描述 请实现一个函数,将一个字符串中的每一个空格替换成“%20”。例如,当字符串为We Are Happy.则通过替换以后的字符串为We%20Are%20Happy。git # -*- coding:utf-8 -*- class Solution: # s 源字符串 def rep
相关文章
相关标签/搜索