Added functionality for multiple char delimiters

Added a boolean parameter to see whether the the string included [] or
not