Is there a code with which i can replace certain areas of a larger code while only one line

For example, i have:

import excel "D_EU_Austria.xlsx", sheet("Price History")
gen D_EU_Austria = ln(Total_Return_Gross_Unh / Total_Return_Gross_Unh[_n-1])
keep D_EU_Austria Date
drop if D_EU_Austria == 0
drop if D_EU_Austria == .
save "D_EU_Austria.dta", replace

Can I replace every instance of D_EU_Austria in my code with something else by writing it only once? I have to repeat this entire code for 20 countries.

Thank you so much (first time poster)