0

I have a text file and I want to remove a part of text using Python 3.7.

Example:

helloooooooooooooo ### 122
How Are uuuuuuuuuuuuuuuuuuuuu?
GigaEthernet              0          1          0
GigaEthernet              1           2          0
GigaEthernet               2         1            3 
helloooooooooooooo ### 122
helloooooooooooooo ### 122

i want the text file change to:

GigaEthernet              0          1          0
GigaEthernet              1           2          0
GigaEthernet               2         1            3

It maybe "FastEthernet" instead of GigaEthernet so we should consider "Ethernet" as a key word).

fabrik
  • 14,094
  • 8
  • 55
  • 71

1 Answers1

1

Instead of giving you a complete solution, I'll help on how to approach this kind of problem. What do you have? A file. What do you want? A modified file.

I hope that this helps.

Little Helper
  • 1,870
  • 3
  • 12
  • 20