Changes

Jump to: navigation, search

OPS435 Assignment 1 for Section B

67 bytes added, 21:35, 8 October 2020
Overview
[[Category:OPS435-Python]][[Category:rchan]]
= Overview =
When making back up of data files or log filesapplying for a bank account, it is accepting a very common practice to name the backup directories and/job, or files based on the date the backup was done. In order to restore or locate the directory/filesome other activity that is personal, we often need to find out it may involve the backup date from todayprocessing of someone's dateof birth. It is critical for this type of data to be validated before being processed by a computation system.
The computational task for this assignment is to design an algorithm and write a python script according to your algorithm with appropriate functionsvalidate a given string in various forms as the date of birth of someone and convert it into a standard format. The DOB conversion script should take two dates a date in the following four formats: "YYYYMMDD", "YYYY/MM/DD", "YYYY-MM-DD", and "YYYY.MM.DD" format and return the number date in a standard format: 'mmm d, yyyy", where "mmm" is the three letter abbreviated month's name, 'd' is a one or two-digit day of days from the first to month, and 'yyyy' is the second datefour-digit year. That is, if the user enters "1820201007", or "2020-0610-07", or "2020/10/07" and , or "25-06-2020.10.07", the script will return "Oct 7, 2020". Similarly, if the target date is in the past, the script will return a negative number. In addition, if the user enters one date only, then the number returned should be the number of days between today's date and the specified dateMore examples to follow.
= Assignment Requirements =
1,760
edits

Navigation menu