Query regarding best practices to credit original developers

Makes perfect sense, i’ll take care from next time!!, can you advice me how to credit coding train back, as I have used their code.