Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please solve it as soon as possible by using python 3 code. only one house left .help me. Take two lists from the user (elements

image text in transcribed

please solve it as soon as possible by using python 3 code. only one house left .help me.

Take two lists from the user (elements of the lists separated by space) of the same size. The first list will contain some names and the second list will contain roll numbers. Your job is to assign each name a roll number from the list containing numbers following the criteria given below: Find the sum of the ASCII value of each name and then sort the names in descending order based on the sum. Then assign the lowest number to the name that has the highest ASCII value sum as a roll number. Sample Input 1: Alan Jack Nancy Jim 10 15 20 50 Sample Output 1: Nancy's roll number is: 10 Alan's roll number is: 15 Jack's roll number is: 20 Jim's roll number is: 50 Explanation1: Here, the summation of the ASCII value of each name are: Nancy(505), Alan (380), Jack(377) and Jim(288). So, Nancy got the lowest number (10) from the number list as roll number, then Alan got the second lowest (15), followed by Jack(20) and Jim (50)

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

Step: 3

blur-text-image

Ace Your Homework with AI

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

Get Started

Recommended Textbook for

Data Management Databases And Organizations

Authors: Watson Watson

5th Edition

0471715360, 978-0471715368

Students also viewed these Databases questions

Question

Discuss the Hawthorne experiments in detail

Answered: 1 week ago

Question

Explain the characteristics of a good system of control

Answered: 1 week ago

Question

State the importance of control

Answered: 1 week ago

Question

What are the functions of top management?

Answered: 1 week ago