Use the ‘loop_end’ action hook to check if the current loop is the last one.
Check out this post for example on how you can apply the hook
Determine if Query is on last Loop
Check your the settings on the permalinks section. Set them to their defaults and if you want to customize them to suite your needs then you can follow this tutorial on permalinks
I think you need to install the External Links plugin then head over to your Widgets section and add the RSS widget to your site. Select the option to open external links in a new window. Save your changes and you’re done.