Computer Science
Related Questions
Write a Python program to generate and print a list of first and last 5 elements where the values are square of numbers between 1 and 30 (both included).
Write a Python program to get unique values from a list.
Write a Python script to concatenate the following dictionaries to create a new one:
d1 = {'A': 1, 'B': 2, 'C': 3} d2 = {'D': 4 }
Output should be:
{'A': 1, 'B': 2, 'C': 3, 'D' : 4}
Write a Python script to check if a given key already exists in a dictionary.