Answers for "py split list"

24

split string python

file='/home/folder/subfolder/my_file.txt'
file_name=file.split('/')[-1].split('.')[0]
Posted by: Guest on April-01-2020
0

how to split word in python

text= "I am Batman"
splitted_text= text.split()

Print(splitted_text)
Posted by: Guest on September-02-2020

Python Answers by Framework

Browse Popular Code Answers by Language