Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Make a list
#1
Sorry for this format, just trying to figure this out.
i'm trying to take a string including many of (words, numbers, empty spaces, empty lines, multiple lines of text and punctuation) and separate them into 2 lists containing the characters before each set of group of a variable of (letters and pucntuation) on a line and each group after each same set of group of variable (letters and punctuation) and list those two groups in two separate lists. Also, to create a list of the variable set of (letters and punctuation) after the set of group of (letters and punctuation) before the set of same set of group of (letters and punctuation) on the same line of text. all the text is in a .txt file
Reply
#2
Hard to understand what you want. Maybe better if you give an example of what you start with, and what your output should look like.

Just a small example.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Why do I have to repeat items in list slices in order to make this work? Pythonica 7 2,916 May-22-2023, 10:39 PM
Last Post: ICanIBB
  help me to make my password list in python >>> Oktay34riza 0 1,024 Dec-23-2022, 12:38 PM
Last Post: Oktay34riza
  Make Groups with the List Elements quest 2 2,704 Jul-11-2021, 09:58 AM
Last Post: perfringo
Question How to make a 3D List of Excel Spreadsheets? chatguy 4 3,724 Jan-24-2021, 05:24 AM
Last Post: buran
  Undo interation to make a single list? DustinKlent 2 2,870 Nov-29-2020, 03:41 AM
Last Post: DustinKlent
  How to make global list inside function CHANKC 6 4,291 Nov-26-2020, 08:05 AM
Last Post: CHANKC
  How do i make a new lists out of an list ozezn1 1 2,222 Oct-28-2020, 10:19 PM
Last Post: Gribouillis
  Make list of dates between today back to n days Mekala 3 3,134 Oct-03-2020, 01:01 PM
Last Post: ibreeden
  How to make a list of values from a dictionary list? faryad13 2 2,768 Sep-03-2020, 03:45 PM
Last Post: faryad13
  List index out of range error when attempting to make a basic shift code djwilson0495 4 4,253 Aug-16-2020, 08:56 PM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020