Learning Regular Expression might not be a tough job but writing a correct regular expression requires experience and hell lot of patience. Especially for newbee, it will be tough job to apply what have been learnt from the text book or Internet without the help of a good utility.
In this case, I would recommend an utility that is known as RegExr. This utility allows you to see real time Regular Expression procesing against some text that you intend to extract from. Below is the picture that shows how you can extract the substring "]." that is located at the end of the string line.
This utility actually comes in two forms, a web based and a desktop based applications. You can download the utility from this url for free http://www.gskinner.com/RegExr/desktop/