Add a new profile to a batch of users

Hi guys
I have a batch of users identifiable by @ in their username
I want to drop the old profile and add a new one for all the users.
The users are about 900.
Any suggestion will be appreciated.
Thanks

I’ve been able to write a script to add new profile but unable to drop the old profile.
Any idea?