Python Forum
how to remove none from the for loop
Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to remove none from the for loop
#6
Just repeating what others have said: 

c = " domain ontologies"

mystr = c.split()
print(mystr[0])
print(mystr[1])
Output:
domain ontologies
If it ain't broke, I just haven't gotten to it yet.
OS: Windows 10, openSuse 42.3, freeBSD 11, Raspian "Stretch"
Python 3.6.5, IDE: PyCharm 2018 Community Edition
Reply


Messages In This Thread
how to remove none from the for loop - by desul - Feb-27-2017, 01:30 PM
RE: how to remove none from the for loop - by wavic - Feb-27-2017, 01:46 PM
RE: how to remove none from the for loop - by buran - Feb-27-2017, 01:55 PM
RE: how to remove none from the for loop - by desul - Feb-27-2017, 04:11 PM
RE: how to remove none from the for loop - by sparkz_alot - Feb-27-2017, 07:17 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  [PyKML] Loop through all Placemarks; Remove namespace Winfried 2 3,556 Aug-28-2020, 09:24 AM
Last Post: Winfried
  python multiprocessing import Pool, cpu_count: causes forever loop | help to remove Hassibayub 0 1,929 Jun-18-2020, 05:27 PM
Last Post: Hassibayub

Forum Jump:

User Panel Messages

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