'Fill in the missing line in the program using the "search" function of the regular expression Python library:
The following program finds and prints only lines in the mbox.txt file that end with 'java'. Fill in the missing line in the program using the "search" function of the regular expression Python library:
import re hand = open('mbox-short.txt') for line in hand: line = line.rstrip() ____________________________ print(line)
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
