Question: PLEASE SOLVE THIS WITH R STUDIO AND PLEASE FOLLOW THE RULES below data are the txt files 1. cards.txt 2. names.txt 3. passwords.txt - The

PLEASE SOLVE THIS WITH R STUDIO AND PLEASE FOLLOW THE RULES

PLEASE SOLVE THIS WITH R STUDIO AND PLEASE FOLLOW THE RULES belowdata are the txt files 1. cards.txt 2. names.txt 3. passwords.txt -

The exercises focus on using regular expressions and the stringer functions. -

below data are the txt files

1. cards.txtDon't use any control statements. - Please find and download the corresponding

2. names.txt

3. passwords.txt

files on the course website to complete the tasks below. - For

each pattern, store the pattern as a variable named in the way

- The exercises focus on using regular expressions and the stringer functions. - Don't use any control statements. - Please find and download the corresponding files on the course website to complete the tasks below. - For each pattern, store the pattern as a variable named in the way pat_ x_y where the x is the number of the exercise and the y is the letter of the sub-exercise. - You should save these patterns in your .R file. - You may demonstrate your patterns with any appropriate stringer functions. - The accuracy of your patterns account for 60% of this assignment. 1. Find names.txt and write regex patterns to answer following questions. a. Find all usernames that contain at least one numeric character. b. Find all usernames that are exactly four characters long and consist only of alphabetic characters. c. Find all usernames following the conventional way of name format, i.e., the "given name" goes first, and the "family" name last, with any other names in-between. The names are separated by a single white space and each name should be uppercase letter followed by one or more lowercase letters. 2. Find cards.txt and write the regex patterns to identify all the valid card numbers with the formatting rules below 2. - A Master card number begins with a 5 and it is exactly 16 digits long. - A Visa card number begins with a 4 and it is between 13 and 16 digits long. a. Write a regex pattern to match valid Master card number and print all the valid numbers, grouped into sets of 4 separated by a single space. b. Write a regex pattern to match valid Visa card number and print all the valid numbers, grouped into sets of 4 separated by a single space. Note: You may use more than one stringer function for both questions above. 3. Find the passwords.txt and write regex patterns to answer the following questions. a. Write a regex pattern to identify the passwords that satisfies the requirements below. - Minimum 8 characters - Must contain at least one letter b. Write a regex pattern to identify the passwords that satisfies the requirements below. - Minimum 8 characters - Must contain at least one uppercase character - Must contain at least one lowercase character - Must contain at least one digit Please load wordlists.RData to R and write regular expression patterns which will match al. of the values in x and none of the values in y. a. Ranges b. Backrefs \( \begin{array}{rl}1 & \text { abc123 } \\ 2 & \text { horribleTurtle } \\ 3 & \text { messsages } \\ 4 & \text { keep_it_simple } \\ 5 & \text { hello world! } \\ 6 & \text { Zoran D Wang } \\ 7 & \text { myUsernameis210 } \\ 8 & \text { abc defg } \\ 9 & \text { asml } \\ 10 & \text { john } \\ 11 & \text { Edward Lazowska } \\ 12 & 123 f i o n a F o g \\ 13 & \text { Red chihuahua5 } \\ 14 & 1 \\ 15 & \text { CLEAN } \\ 16 & \text { +plus+ } \\ 17 & \text { omaha poshy } \\ 18 & \text { Omaha p0shy } \\ 19 & \text { OMAHA POSHY } \\ 20 & \end{array} \) passwords.txt 123456789101112123456712345678Strings78apple0071brownieasdfjkl90095glhf1234789afkalllowercaseALLUPPERCASEmissingNumbers

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!