how do i code this in python Your program should be able to process any of the three transactions each time it runs. (You need to include appropriate input operations to get data from the user, however, due to the nature of this problem, you should not include any user prompt text as part of your input.) Because we have yet to do looping, your program does not need to process more than one transaction at a time. However, your program must recognize the transaction that is being requested and process accordingly. Before doing any transaction processing, your program should do the following error checking on the provided data: testing for valid customer number (does the customer number exist on the company's customer list?) is the transaction type valid? This is the only error checking you need to do -- you may assume all other data provided will be valid If the data is invalid, you should print one or both of the following messages: Customer number ##### is invalid. Transaction type XX is invalid. After reporting one or both of these error messages, you should not do any further processing. If both the customer number and transaction type are valid, you should continue processing based on the transaction type as described below: Customer Name Change From the customer name change transaction data provided, construct a revised name in the format Last Name, First Name Middle (ex: Johnson, Jimmy James) update the appropriate customer name print the customer_name list (entire list, not individual item) Customer Password Change Evaluate the new password to see if it is secure according to the following rules: At least 6 characters in length (not counting spaces) Having the first four characters as follows: first character an upper case letter second character a lower case letter third character a number fourth character one of the following: !@#$%^&*() (you do not need to check after the fourth character) If the new password is not secure: print the following message: New password not secure. Request denied. (No further processing is necessary) If the new password is secure, update the password in the customer data print the customer_password list (entire list, not individual item)

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Topic Video
Question

how do i code this in python

Your program should be able to process any of the three transactions each time it runs. (You need to include appropriate input operations to get data from the user, however, due to the nature of this problem, you should not include any user prompt text as part of your input.) Because we have yet to do looping, your program does not need to process more than one transaction at a time. However, your program must recognize the transaction that is being requested and process accordingly.

Before doing any transaction processing, your program should do the following error checking on the provided data:

  • testing for valid customer number (does the customer number exist on the company's customer list?)
  • is the transaction type valid? This is the only error checking you need to do -- you may assume all other data provided will be valid

If the data is invalid, you should print one or both of the following messages:

  • Customer number ##### is invalid.
  • Transaction type XX is invalid.

After reporting one or both of these error messages, you should not do any further processing.

If both the customer number and transaction type are valid, you should continue processing based on the transaction type as described below:

Customer Name Change

From the customer name change transaction data provided,

  • construct a revised name in the format Last Name, First Name Middle (ex: Johnson, Jimmy James)
  • update the appropriate customer name
  • print the customer_name list (entire list, not individual item)

Customer Password Change

Evaluate the new password to see if it is secure according to the following rules:

  • At least 6 characters in length (not counting spaces)
  • Having the first four characters as follows:
    • first character an upper case letter
    • second character a lower case letter
    • third character a number
    • fourth character one of the following: !@#$%^&*()
    • (you do not need to check after the fourth character)

If the new password is not secure:

  • print the following message:
    • New password not secure. Request denied.
    • (No further processing is necessary)

If the new password is secure,

  • update the password in the customer data
  • print the customer_password list (entire list, not individual item)
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 2 images

Blurred answer
Knowledge Booster
Instruction Format
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education