Redirect non-www to www using .htaccess

The code below added at the begining of the .htaccess file, will redirect non-www urls to corespondent www, as expected: