These are the tables that I am trying to match: table 1 and table 2
table1 = pd.DataFrame({'Name': ['Patrick', 'Amy', 'Krish', 'Jack']})
table2 = pd.DataFrame({'Name': ['Patrick', 'Patrick', 'Jack', 'Amy', 'Rachel', 'Kim', 'Amy'],
'Age': [20,19,19,18, 45, 32, 17],
'Number of Job Offer': [1,2,3,4, 5, 6, 8] })
This is the expected outcome: expected outcome
Can anyone please show me how I can get that in Python? Thank you