please help me asap please Write a python program that will take input from the user until the user  gives “STOP” as input. In every line the user will provide input as follow: [Brand Name] [PRICE] Your task is to create a dictionary where the brand’s name will be key and  the value will be a list of that brand’s watches ID. ID generate process:  inputno_FirstTwoLetterOfBrand_Price. Finally print the dictionary. Sample Input 1: OMEGA 10000 TITAN 5000 TITAN 3000 CREDENCE 150000 OMEGA 12000 CREDENCE 90000 STOP Sample Output 1: {'OMEGA': ['1_OM_10000', '5_OM_12000'], 'TITAN':  ['2_TI_5000', '3_TI_3000'], 'CREDENCE': ['4_CR_150000', '6_CR_90000']} Sample Input 2: CREDENCE 5000 CREDENCE 11000 OMEGA 8000 TITAN 7500 QUARTZ 8000 CASIO 6000 CASIO 7000 STOP Sample Output 2: {'CREDENCE': ['1_CR_5000', '2_CR_11000'], 'OMEGA': ['3_OM_8000'], 'TITAN':  ['4_TI_7500'], 'QUARTZ': ['5_QU_8000'], 'CASIO': ['6_CA_6000', '7_CA_7000']}

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
Question

please help me asap

please

Write a python program that will take input from the user until the user 
gives “STOP” as input. In every line the user will provide input as follow:
[Brand Name] [PRICE]
Your task is to create a dictionary where the brand’s name will be key and 
the value will be a list of that brand’s watches ID. ID generate process: 
inputno_FirstTwoLetterOfBrand_Price. Finally print the dictionary.

Sample Input 1:
OMEGA 10000
TITAN 5000
TITAN 3000
CREDENCE 150000
OMEGA 12000
CREDENCE 90000
STOP
Sample Output 1:
{'OMEGA': ['1_OM_10000', '5_OM_12000'], 'TITAN': 
['2_TI_5000', '3_TI_3000'], 'CREDENCE': ['4_CR_150000', '6_CR_90000']}

Sample Input 2:
CREDENCE 5000
CREDENCE 11000
OMEGA 8000
TITAN 7500
QUARTZ 8000
CASIO 6000
CASIO 7000
STOP
Sample Output 2:
{'CREDENCE': ['1_CR_5000', '2_CR_11000'], 'OMEGA': ['3_OM_8000'], 'TITAN': 
['4_TI_7500'], 'QUARTZ': ['5_QU_8000'], 'CASIO': ['6_CA_6000', '7_CA_7000']}

Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Binary Search Algorithm
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