CSE-3342 Programming Languages: PerlAssignment_5: Guess using Regular Expressions 100 ptsDue Date: 05 March, Tuesday, 2019Write a program called guess (guess.pl) using regular expressions that try to guess what you entered. You may use your own choice of method(s) based on your approach (optional). The skeleton of the program is straight forward which is as follows: It consists of an infinite loop that iterates until the last function is called. If the user enters quit, then the program will exit otherwise your program applies several regular expressions to the user’s input to try to determine entered data. If the input does not match any of the regular expressions, then program display a message indicating that “no match was found.” Regular expressions should match input data which are listed below:first name and last name: John Quincy AdamsThe regular expression should determine the input data is male or female: The regular expression should check the input data is street address: 5454 Amesbury DrThe regular expression matches the city, state and zip code: Dallas, TX 75206The regular expression should match the email address The regular expression should match the phone numberThe regular expression for currencyT代做CSE-3342作业、代写Java编程作业、代做c/c++,Python语言作业、代写Programming作业 调he regular expression for Monetary Input: $55.00 or $0.75, etc The regular expression for debit or credit card numberThe regular expression for dateThe regular expression for time The regular expression for URLThe regular expression for IP AddressYou should follow the naming convention that is used for Perl programming. Program should include comments that explain each block of code or important statement. Turn in to Canvas1)Write the program in Perl, execute your program, capture output and submit a pdf file to Canvas2)Execute all possible test cases and document your results in pdf against each regular expression for example, your regular expression should cover all possible date format or time format: 12 hr or 24 hr am, pm etc. same for different cards. 3)Submit: guess.pl file to CanvasWe will discuss this and few other assignments in this lecture sessionReferences[1] Wikipedia, IP address [available online] https://en.wikipedia.org/wiki/IP_address [accessed 09/24/2018][2] Wikipedia, Calendar date [available online] https://en.wikipedia.org/wiki/Calendar_date [accessed 09/24/2018].[3] Wikipedia, payment card number [available online] https://en.wikipedia.org/wiki/Payment_card_number [accessed 09/24/2018]. 转自:http://ass.3daixie.com/2019030729243833.html
讲解:CSE-3342、Java、c/c++,Python、ProgrammingMatlab|Web
©著作权归作者所有,转载或内容合作请联系作者
- 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
- 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
- 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
推荐阅读更多精彩内容
- CSE-3342 Programming Languages: PerlAssignment_5: Guess u...
- CSE-3342 Programming Languages: PerlAssignment_5: Guess u...