2 ms·Could you post a rewritten version?by amelius 4y agoCould you post a rewritten version?alpaca128 4y agoSomething like this with open("beef.txt") as file: lines = [line for line in file if "lasagna" in line] print(set(lines))