Welcome to the Airtable community!
It sounds like you are new to writing scripts and are very focused on accomplishing your specific tasks. However, if you want to learn to write scripts yourself, please listen to Dominik’s advice to “learn the fundamentals” of JavaScript first.
On the other hand, if you just want working code, but are not actually interested in learning to code, that’s fine as long as you let people know what you want.