# Basic syntax: foreach var (list) { code to run; } # Example usage: @list = (2, 20, 30, 40, 50); foreach $i (@list) { print "Value of i: $i "; }