Make a function that produces a regex based on keywords.
$10-30 USD
Kiszállításkor fizetve
We want to be able to dynamically build a RegExp that identifies urls. We will give in input a pattern containing keywords and jollies and a string containing many urls.
Build a function 'matchPattern(pattern, str)' that, given a primitive pattern and a string containing urls in input, constructs a regex as:
- Everything should be enclosed by quotes (either "" or '')
- pattern may contain {number} or {string} variables. Replace them with zero to unlimited 1-9 and A-z
Finally the function should return matched pattern(s) based on str parameter.
Examples
matchPattern("/job/{string}/{string}","\"[login to view URL]\"")
returns -> [login to view URL]"
matchPattern("/job/{number}/{string}","'[login to view URL]'")
returns -> False
matchPattern("/job/{string}","[login to view URL]")
returns -> False # No enclosing quotes
matchPattern("/{string}/{string}","'[login to view URL]'")
returns -> [login to view URL]
matchPattern("/{string}/{string}","[login to view URL]")
returns -> False # No enclosing quotes
matchPattern("/{string}/{string}","['/str/str','/abc/efg']")
returns -> Array(['/str/str','/abc/efg'])
matchPattern("/{string}?a","<a href='[login to view URL]' />")
returns -> [login to view URL]
Projektazonosító: #28979572
A projektről
Odaítélve:
Hi, I just read the description and rules. I can write the expression right away. Ping me on chat. Thanks.
6 szabadúszó tett átlagosan 52$ összegű árajánlatot erre a munkára
i am ready to start now Have read your description on project very carefully. I'm a professional developer with 1+ year experience as you can see my profile. Have completed many similar projects perfectly till now and Továbbiak
✔️✔️✔️High ✔️python Hello. how are you doing today? I am interested in your project and understood you are looking for a ✨Python Developer✨ to make a function that produces a regex based on keywords. I'm a full stack Továbbiak
Hello, I read your project description and I am happy to introduce myself to you. I am a professional software engineer with more than 7 years of experience in building software/Website using .NET technologies and too Továbbiak
hi, I am an experienced python developer. It is a very easy task for me. I have read your project's description. I can do it however you want it to be, no problem. So please feel free to response me, good luck.