Question: Write a regular expression that finds all of the occurrences of the word a in the following sentence and replaces them with the: a dog
Write a regular expression that finds all of the occurrences of the word “a” in the following sentence and replaces them with “the”: “a dog walked in off a street and ordered a finest beer” The sentence should become: “the dog walked in off the street and ordered the finest beer”
Step by Step Solution
3.52 Rating (162 Votes )
There are 3 Steps involved in it
With regular expressions its often not just what you want to match but also what you dont ... View full answer
Get step-by-step solutions from verified subject matter experts
