Which command is used to search a file for lines that contains an - ProProfs Discuss
Advertisement

Which command is used to search a file for lines that contains an asterisk(*) character in Linux operating system?

Which command is used to search a file for lines that contains an asterisk(*) character in Linux operating system?

Change Image    Delete

Asked by Abigail, Last updated: Nov 09, 2024

+ Answer
Request
Question menu
Vote up Vote down

1 Answer

John Smith

John Smith

John Smith
John Smith

Answered Sep 08, 2016

Grep \\* textfile-2. grep \ *\ textfile-3. grep \"*\" textfile-grep, sed, tail, head, less, sort, cut etc are string processing tools, which uses different symbls to match the pattern. whildcard charaacter: . àany single character * àzero or more character [abc] àany single character from the range [^abc] àany single character except from the range similarly anchors ^ àline beigns with $ àline ends with \\< àword beigns with \\> àword ends with so grep search the pattern and displays all lines matching the pattern. but * is the meaningfull character so to kill the meaning of meaningfull characters should use \\.
upvote downvote
Reply 

Advertisement
Advertisement
Search for Google images Google Image Icon
Select a recommended image
Upload from your computer Loader
Image Preview
Search for Google images Google Image Icon
Select a recommended image
Upload from your computer Loader
Image Preview
Search for Google images Google Image Icon
Select a recommended image
Upload from your computer Loader

Email Sent
We have sent an email to your address "" with instructions to reset your password.