A teacher has two lists of the same length. rolls has the roll numbers of the students and names has their names, in the same order: the student with roll number rolls[0] is names[0], and so on. All the roll numbers are different.
Write a function make_roll_book(rolls, names) that returns a dictionary in which every roll number is a key and the name of that student is its value. If the lists are empty, return an empty dictionary.
The keys of your dictionary can be in any order. The examples show them in sorted order.
NOTE: This is a function type question, you don't have to take input or print the output, just have to complete the required function definition.
make_roll_book([101, 102, 103], ["Asha", "Bala", "Chitra"]) -> {101: 'Asha', 102: 'Bala', 103: 'Chitra'}
make_roll_book([7], ["Ravi"]) -> {7: 'Ravi'}
Implement this function:
def make_roll_book(rolls: list, names: list) -> dict:
Write the function only — the arguments are read for you and the return value is printed automatically.
Arguments arrive as one Python literal per line, in this order: rolls, names.
Input
[101, 102, 103]
["Asha", "Bala", "Chitra"]
Output
{101: 'Asha', 102: 'Bala', 103: 'Chitra'}

A teacher has two lists of the same length. `rolls` has the roll numbers of the students and `names` has their names, in the same order: the student with roll number `rolls[0]` is `names[0]`, and so on. All the roll numbers are different. Write a function `make_roll_book(rolls, names)` that returns a dictionary in which every roll number is a key and the name of that student is its value. If the lists are empty, return an empty dictionary. The keys of your dictionary can be in any order. The examples show them in sorted order. NOTE: This is a function type question, you don't have to take input or print the output, just have to complete the required function definition. ### Example ``` make_roll_book([101, 102, 103], ["Asha", "Bala", "Chitra"]) -> {101: 'Asha', 102: 'Bala', 103: 'Chitra'} make_roll_book([7], ["Ravi"]) -> {7: 'Ravi'} ``` ## Your task Implement this function: ```python def make_roll_book(rolls: list, names: list) -> dict: ``` Write the function only — the arguments are read for you and the return value is printed automatically. **Arguments** arrive as one Python literal per line, in this order: `rolls`, `names`. ## Example **Input** ``` [101, 102, 103] ["Asha", "Bala", "Chitra"] ``` **Output** ``` {101: 'Asha', 102: 'Bala', 103: 'Chitra'} ``` A shop keeps its price list in a dictionary `prices`. Each key is the name of an item and its value is the price of that item in rupees (an integer, 0 or more). Write a function `item_price(prices, item)` that returns the price of `item`. If `item` is not a key of `prices`, return `-1`. The names are case sensitive: `"Pen"` and `"pen"` are two different items. An item that is in the dictionary with the price 0 has the price 0, not -1. NOTE: This is a function type question, you don't have to take input or print the output, just have to complete the required function definition. ### Example ``` item_price({"pen": 10, "notebook": 45, "eraser": 5}, "notebook") -> 45 item_price({"pen": 10, "notebook": 45, "eraser": 5}, "scale") -> -1 ``` ## Your task Implement this function: ```python def item_price(prices: dict, item: str) -> int: ``` Write the function only — the arguments are read for you and the return value is printed automatically. **Arguments** arrive as one Python literal per line, in this order: `prices`, `item`. ## Example **Input** ``` {"pen": 10, "notebook": 45, "eraser": 5} "notebook" ``` **Output** ``` 45 ``` A class is choosing its monitor. `votes` is a list of names: each element is one vote for that student. Write a function `count_votes(votes)` that returns a dictionary in which every name that got at least one vote is a key and the number of votes for that name is its value. If `votes` is empty, return an empty dictionary. The names are case sensitive: `"meena"` and `"Meena"` are counted separately. The keys of your dictionary can be in any order. The examples show them in sorted order. NOTE: This is a function type question, you don't have to take input or print the output, just have to complete the required function definition. ### Example ``` count_votes(["Meena", "Arjun", "Meena", "Kiran", "Meena", "Arjun"]) -> {'Arjun': 2, 'Kiran': 1, 'Meena': 3} count_votes(["Zoya"]) -> {'Zoya': 1} ``` ## Your task Implement this function: ```python def count_votes(votes: list) -> dict: ``` Write the function only — the arguments are read for you and the return value is printed automatically. **Arguments** arrive as one Python literal per line, in this order: `votes`. ## Example **Input** ``` ["Meena", "Arjun", "Meena", "Kiran", "Meena", "Arjun"] ``` **Output** ``` {'Arjun': 2, 'Kiran': 1, 'Meena': 3} ```