Python program to remove empty strings from a list
# take list
my_list = ['Know Program', '', 'Python', 'C', '', 'Java']
# printing original list
print('List:', my_list)
# remove empty string using native method
new_list = []
for i in my_list:
if (i):
new_list.append(i)
# printing list without empty string
print('New List:', new_list)