Skip to content

Commit 8fb1a66

Browse files
Fixing
1 parent 4c57734 commit 8fb1a66

File tree

1 file changed

+29
-29
lines changed

1 file changed

+29
-29
lines changed

README.md

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -144,35 +144,6 @@ x.printString()
144144
* * *
145145

146146

147-
## Question_6: ##
148-
**Description:**
149-
150-
Write a program that accepts a comma separated sequence of words as input and prints the words in a comma-separated\
151-
sequence after sorting them alphabetically.\
152-
Suppose the following input is supplied to the program:\
153-
* without,hello,bag,world
154-
Then, the output should be:\
155-
* bag,hello,without,world\
156-
157-
**Hints:**
158-
In case of input data being supplied to the question, it should be assumed to be a console input.
159-
160-
```python
161-
def prog_3():
162-
x = input()
163-
list_ = []
164-
165-
for a in x.split(","):
166-
list_.append(a)
167-
list_.sort()
168-
str_ = ",".join(list_)
169-
print(list_)
170-
print(str_)
171-
return
172-
prog_3()
173-
```
174-
* * *
175-
176147
## Question_6: ##
177148
**Description:**
178149

@@ -201,3 +172,32 @@ def two_dimens_arr(x, y):
201172
two_dimens_arr(4, 4)
202173
```
203174
* * *
175+
176+
## Question_7: ##
177+
**Description:**
178+
179+
Write a program that accepts a comma separated sequence of words as input and prints the words in a comma-separated\
180+
sequence after sorting them alphabetically.\
181+
Suppose the following input is supplied to the program:\
182+
without,hello,bag,world
183+
Then, the output should be:\
184+
bag,hello,without,world\
185+
186+
**Hints:**
187+
In case of input data being supplied to the question, it should be assumed to be a console input.
188+
189+
```python
190+
def prog_3():
191+
x = input()
192+
list_ = []
193+
194+
for a in x.split(","):
195+
list_.append(a)
196+
list_.sort()
197+
str_ = ",".join(list_)
198+
print(list_)
199+
print(str_)
200+
return
201+
prog_3()
202+
```
203+
* * *

0 commit comments

Comments
 (0)