My dataset:
data={'A':['1210226','1210226','1210226','1210302','1210336','1210336','1210336'],'B':['','','2@.com','1@.com','','','1@.com']}
df=pd.DataFrame(data)
print(df)
I filter the column to blanks in excel == python( used is.null)
Data set in excel

The condition I want to apply in pandas is =IF(A1=A3,B3,"") formula is written in excel ( please review the image), and sheet is filtered with blanks. I know O have to use is.null() then i want to apply condition to the is.null in order to get required output.

Final output should be something like below image

>Solution :
You can try the following:
data={'A':['1210226','1210226','1210226','1210302','1210336','1210336','1210336'],'B':['','','2@.com','1@.com','','','1@.com']}
df=pd.DataFrame(data)
df.drop("B", axis=1).merge(df.groupby("A").max(), on="A")
Output:
A B
0 1210226 2@.com
1 1210226 2@.com
2 1210226 2@.com
3 1210302 1@.com
4 1210336 1@.com
5 1210336 1@.com
6 1210336 1@.com