How old should your puppy be when you enroll them in classes?

and how old should they be when they go to a dog park?