Analyst and Data Scientist Interview Questions

What is the difference between a primary key and a foreign key in a database?

Explain the concept of normalization in databases.

How would you optimize a SQL query that joins multiple tables and is performing slowly?