链接 557. Reverse Words in a String III
题目
Given a string s, reverse the order of characters in each word within a sentence while still preserving whitespace and initial word order.
题解
暴力写,没啥好说的
1 | class Solution: |
不考虑重复遍历的话,一行流也行
1 | class Solution: |
链接 557. Reverse Words in a String III
Given a string s, reverse the order of characters in each word within a sentence while still preserving whitespace and initial word order.
暴力写,没啥好说的
1 | class Solution: |
不考虑重复遍历的话,一行流也行
1 | class Solution: |