def addSpacesBetweenHashTags(text):
    """ Add spaces between hastags: #i#love#newyork -> #i #love #newyork """
    if len(text) == 0:
        return ''

    # Add spaces if hashtags are togerther
    new_text = ''
    for i, c in enumerate(text, start=0):
        if (c in ['#', '@']) and (i > 0):
            if text[i - 1] != ' ':
                new_text += ' '
        new_text += c
    return new_text