【资料图】
字符串消除空格
输入一个字符串,将这个字符串中所有的空格删除
输入格式:
输入一个字符串
输出格式:
输出删除空格后的字符串
输入样例:
i am a boy! you are a girl!
输出样例:
iamaboy!youareagirl!
答:
s = input()
new_s = "".join(s.split())
print(new_s)
【资料图】
输入一个字符串,将这个字符串中所有的空格删除
输入一个字符串
输出删除空格后的字符串
i am a boy! you are a girl!
iamaboy!youareagirl!
答:
s = input()
new_s = "".join(s.split())
print(new_s)
2023-04-19
2023-04-19
2023-04-19
2023-04-19
2023-04-19
2023-04-19
2023-04-19
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-18
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-17
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-16
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-15
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-14
2023-04-13
2023-04-13
2023-04-13
2023-04-13
2023-04-13
2023-04-13