20 Python interview questions for Data Engineers
• What are Python lists and how are they different from tuples?
• How do you create a dictionary in Python and access its values?
• Explain list comprehension and provide an example.
• How can you read a CSV file in Python using pandas?
• What is the difference between loc and iloc in pandas?
• How do you handle missing data in a pandas DataFrame?
• Explain the use of the apply() function in pandas.
• How can you merge/join two DataFrames in pandas?
• Describe how to group data in pandas and perform aggregation.
• What are NumPy arrays and how do they differ from Python lists?
• How do you perform element-wise operations on NumPy arrays?
• What is the use of the Matplotlib library in Python? Provide an example of a simple plot.
• How do you create subplots in Matplotlib?
• Explain the use of the Seaborn library and provide an example of a categorical plot.
• What is a lambda function in Python and how is it used?
• Describe how to filter a DataFrame based on a condition.
• How do you use the datetime module to manipulate dates and times in Python?
• Explain the difference between a shallow copy and a deep copy in Python.
• How can you perform data normalization or standardization in Python?
• Describe how to use regular expressions in Python for data cleaning.