For example, suppose you have a list of [a,1,2,]
a1
, a2
, 1a
, 2a
, 12
, 21
Is there a way to write atom mixed in this way? ㅜ<
Do not include a
, 1
, 2
, and a12
.
And the numeric string should be converted into a string and then mixed, but I don't know....
Please teach me <
I tried to set the list name to list_data
.
It's Atom, it's list_data, it's all over the place, and let's do it with strong paper, pencil, and hand.
1. First, look at the list carefully. Remember that there are three items in total: a
, 1
and 2
.
2. Since there are three items, write a
on the paper three times vertically. It's going to be like this.
a
a
a
3. Put a
, a
, 1
, and 2
next to a
once. It's going to be like this.
aa
a1
a2
4. Oh! But the teacher said that the same thing should not come out twice like aa
. Clear aaa
with a murmur. It's going to be like this.
a1
a2
5. Write each item three times vertically, put another item next to it, and repeat clearing if there are overlapping items. It's going to be like this when it's done.
a1
a2
1a
12
2a
21
This is the output you want. Why can't you do what you can do with paper, pencils, and hands, Python?
The key is two tours and conditional handling within the tour. Try reading Python Basic Course patiently from start to finish. You can do it.
577 Who developed the "avformat-59.dll" that comes with FFmpeg?
579 Understanding How to Configure Google API Key
585 PHP ssh2_scp_send fails to send files as intended
619 GDB gets version error when attempting to debug with the Presense SDK (IDE)
925 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
© 2024 OneMinuteCode. All rights reserved.