用grep Print all lines containing an uppercase letter, followed by four lowercase letters, a comma, a , and one uppercase letter.
时间: 2024-05-28 14:14:56 浏览: 49
Sure, you can use the following command to grep for the specified pattern:
grep -E '[A-Z][a-z]{4},[a-z],[A-Z]' <filename>
This will print all lines in <filename> that contain an uppercase letter, followed by four lowercase letters, a comma, a lowercase letter, and finally an uppercase letter.
阅读全文