Experts say that at about 18 months old, kids have the ability to understand that a time-out is removing them from the situation. The biggest thing you can do is stay consistent and patient since he may or may not get the time out.
Also remember that toddlers are still like babies in that they likely act out when they are tired, hungry, or sick so try to stay tuned into his moods and don't grocery shop during nap time, etc. if you can and hopefully you can reserve time-outs for when his actions are dangerous.
For now the best thing you can do is state rules because he is just learning and remove him from a situation, but do it as calmly as possible. "We don't throw things at our friends" then take the toy away until he calms down.
I hope that helps good luck


