Question: 1 . [ Points 2 0 ] Regular expression and explain your answer. a . [ Points 5 ] Write a regex to match filenames
Points Regular expression and explain your answer.
aPoints Write a regex to match filenames that end with txt or pdf or rtf
bPoints Write a regex to match dates in the format DDMMYYYY or DDMMYYYY
cPoints Write a regex to extract US phone numbers from a text. The phone numbers can be in the format or
Points
apoints Given the following text documents, apply the text normalization process to get a normalized text. Assume your text normalization process contains the following steps: lowercasing, removing punctuation, tokenization, removing stop words, and stemming. Determine tokens, vocabulary, and types. Please show each step for each document. Build your combined tokens and vocabulary from the given documents, and determine the total number of types, vocabulary, and tokens.
Doc : "She sells sea shells by the seashore."
Doc : "How much wood would a woodchuck chuck if a woodchuck could chuck wood?"
Doc : "A journey of a thousand miles begins with a single step."
bpoints Write a program that normalizes your text, list down the tokens and vocabulary and finally determines the total tokens, vocabulary, and types. Please follow the above steps appropriately in your code so that you can verify your a answer.
points We know how to compute the similarity distance between two given strings using the edit distance algorithm.
aPoints Compute the edit distance for the following strings. Show the initial matrix that converts empty strings to another string given the example below and finally, show the distance for the examples.
String : kitten
String : sitting
bpoints Write down the code to compute edit distance and verify the above answer. Your code should print the distance matrix in each step.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
