Valmiki Ramayana Bala Kanda Sarga 65 Shloka 27
Original Shlokaकृतकामो महीं सर्वां चचार तपसि स्थित:।।1.65.27।। एवं त्वनेन ब्राह्मण्यं प्राप्तं राम महात्मना।
1 source checked for this shloka
कृतकाम: having fulfilled his desire, तपसि in asceticism, स्थित: fixed, सर्वाम् whole, महीम् earth, चचार wandered, राम O Rama, महात्मना by illustrious, अनेन by him, एवम् thus, ब्राह्मण्यम् brahminhood, प्राप्तम् was acquired.
This illustrious sage having fulfilled his desire, wandered over the earth fixed in asceticism. O Rama thus he acquired brahminhood.