autobanner for saying the word "nigger"

i wanted to know if anyone could please make a simple autobanner, for saying the word nigger. if possible, make it so it bans them for an hour the first time, a week the second, and permanent the third? if you do this, you would be thanked in the motd, if you want.



local bantimes = {

["nigger"] = {60 , 10080 , 0},

}
hook.Add("PlayerSay" , "BanNiggers" , function(pl , text , team)
	for k , v in pairs(bantimes) do
		if string.find(string.lower(text) , k) then
			if file.Exists("BannedWords/"..pl:UniqueID().."/"..k..".txt") then
				local num = file.Read("BannedWords/"..pl:UniqueID().."/"..k..".txt")
				
				local time = v[num + 1]
				
				file.Write("BannedWords/"..pl:UniqueID().."/"..k..".txt" , num + 1)
				
				if time then
					pl:Ban(time , string.format("You're a %s." , k))
				else
					pl:Ban(0 , string.format("You're a %s." , k))
				end
				return false
			else
				file.Write("BannedWords/"..pl:UniqueID().."/"..k..".txt" , 1)
				
				pl:Ban(v[1] , string.format("You're a %s." , k))
				return false
			end
		end
	end
end )

Something like that.

why thank you. i know my way around general code, so i can start off off of a lua base code, and modify it / get it working, so thats exactly what i need. where would i put this file? also, lol @ returning the word that bans you and saying no, your a (insert various autoban word here)

Serverside

i know i put it serverside, but in wich folder specifically?

lua/autorun/server