I have two df columns addr_num1 and addr_num2 like below:
addr_num1 addr_num2
10 10
20 20
33 35
40 40
50 53
I want to create a new column such that if the two values are the same, I will use one of them. If not I will combine them like below:
addr_num3
10
20
33-35
40
50-53
How can I do this? Please advise.