This is my input file :
A B B A  
A A A   
B A B A  
B B  
A A  
A B
If all columns are same, I want to print only the first column.
Otherwise, I want to print multi.
Desired output :
multi  
A  
multi  
B  
A  
multi
Can anyone help me?
(I prefer awk or sed.)