This is kinda embarrassing that I'm asking this question at this stage of scripting but I kinda wanna know which method is better.
Method 1: Directly linking a function to an event
local part = game.Workspace.Part
part.Touched:Connect(function()
-- Do stuff
end)
Method 2: Linking a already created function to an event.
local part = game.Workspace.Part
local function Touched()
-- Do stuff
end
part.Touched:Connect(Touched)
Would love to know because I really do want to improve the quality of my scripts.

1 comment
Thanks so much! I'll keep this mind whenever I'm making scripts.