-->
当前位置:首页 > 题库

PROGRAMMING:Sweet troubles

Luz5年前 (2021-05-10)题库604
Recently, Lele learned to use the computer. She found that she can use the computer to solve many things, and the efficiency will be much faster. For example, to find someone's name in a list, in the past, she had to search one by one, which was slow and easy to read wrong. Now, she uses the menu command: "Edit" - "search" (or press the CTRL + F key), in the pop-up search dialog box, enter the name you want to find, and the computer will find the name you want to find or tell you that there is no name you want to find. It's so fast and accurate. It's so cool!
Today, when Bangbang is searching, she enters "Zhangke", and the computer tells her that it doesn't exist, but she inadvertently discovers that "Zhangke" exists! Originally, the person who provided the original list entered a space in the middle for the sake of beautiful format, so the computer couldn't find it. She thought it was easy to solve, so she continued to search for "Zhang chengling", didn't she? Look up "Zhang chengling" (a space in the middle), haven't you? The original number of spaces in the middle of some names is more than one!
Bang Bang wants to delete all the spaces in the middle of the name, but because there are many lists, one by one deletion is too slow, so she found you who can solve the problem by programming. Please write a program to delete all the spaces in the middle of the list.
[data limit] 100% data, 1 ≤ n ≤ 10000, and the number of characters in each line of name is not more than 100.
###Input format:
The first line has only one positive integer n, which means that there are n names in the list.
The second line to the N + 1 line is n lines, each line is a person's name (composed of upper and lower case English letters and spaces between letters).
###Output format:
There are n + 1 rows. The first row has only one positive integer, which represents the total number of spaces deleted.
The second line to the N + 1 line is n lines in total, and each line represents a name after deleting the space (in the order of name input).
###Input example:
```in
three
JiangDongRun
Xu Kai Yang
Ye Han Xi
```
###Output example:
```out
five
JiangDongRun
XuKaiYang
YeHanXi
```






answer:If there is no answer, please comment