Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. (20 points) You are a developer at a company: A&B Inc. which was recently acquired by another company: ACME Corp. Both companies have some

image text in transcribed
1. (20 points) You are a developer at a company: A\&B Inc. which was recently acquired by another company: ACME Corp. Both companies have some common clients, and they have monthly recurring orders from these clients. Luckily, both companies store monthly order numbers in similar python dictionaries. You need to write a function that takes these two dictionaries as input and returns combined order numbers as a dictionary again. \[ \begin{array}{l} \text { AnB_orders }=\left\{{ }^{\prime} \text { Eliz\&Co':200, 'Ayla_Ine ' }: 150 \text {, 'Swan_Ltd': } 400 ight. \text {, } \\ \text { Huan_Ine': } 500 \text {, 'BB_Ltd':300, 'EkA_Inc' :250\} } \\ \text { ACME_orders }=\{\text { Evil_Corp ':450, 'Moon_Inc':150, 'Ayla_Inc': } 230 \text {, } \\ \text { 'Swan_Ltd':600, 'MNM.Ltd':300, 'ElizdCo':350\} } \\ \end{array} \] The return value should look like this: \[ \begin{aligned} \text { combined_orders }=\{ & \text { Evil_Corp':450, 'Moon_Ine':150, 'Ayla_Ine':380, } \\ & \text { Swan_Ltd ':1000, 'Huan_Ine':500, 'MNM_Ltd' }: 300, \\ & \text { BB_Ltd':300, 'ElizdCo':550, 'EDA_Inc':250 } \end{aligned} \]

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions