# Sentence Smash

Write a function that takes an array of words and smashes them together into a sentence and returns the sentence. You can ignore any need to sanitize words or add punctuation, but you should add spaces between each word. **Be careful, there shouldn't be a space at the beginning or the end of the sentence!**

## Example

```
['hello', 'world', 'this', 'is', 'great']  =>  'hello world this is great'
```

Difficulty: EASY
Starter code: def smash(words):
	

Solutions:
def smash(words):
	return ' '.join(words)


smash = ' '.join


smash = lambda x: ' '.join(x)


def smash(words):
	str1 = ' '.join(words)
	return str1


import re

def smash(words):
	return re.sub("[]'',[]", '', str(words))


def smash(words):
	i = 0
	l = len(words)
	str1 = ''
	while i < l:
		if i < l - 1:
			str1 += words[i] + ' '
		else:
			str1 += words[i]
		i += 1
	return str1


smash = lambda w: ' '.join(w)


smash = lambda words: ' '.join(words)


from typing import List

def smash(words: List[str]) -> str:
	return ' '.join(words)


def smash(words):
	out = ''
	for word in words:
		out += word + ' '
	return out.strip()


smash = lambda words, separator=' ': separator.join(words)


def smash(words):
	answer = ''
	for i in words:
		answer += i
		answer += ' '
	return answer[:-1]


def smash(words):
	str = ''
	for w in words:
		str += w + ' '
	return str[:-1]


def smash(words):
	newString = ''
	for i in words:
		newString += i + ' '
	return newString.strip()


def smash(words):
	s = ''
	for v in words:
		s += v
		if v != words[len(words) - 1]:
			s += ' '
	return s


def smash(words):
	str = ''
	for word in words:
		str += word
		str += ' '
	str = str.strip()
	return str


smash = lambda string: ' '.join(string)


def smash(words):
	s = ''
	for (i, j) in enumerate(words):
		if i == 0:
			s += j
		else:
			s += ' ' + j
	return s


def smash(words):
	new = ''
	for word in words:
		new += word + ' '
	return new.strip()


def smash(words):
	final_list = []
	for word in words:
		final_list.append(word)
	return ' '.join(final_list)


def smash(words):
	frase = ''
	for word in words:
		frase += word + ' '
	return frase.strip()


def smash(words):
	return ''.join((s + ' ' for s in words))[:-1]


def smash(words):
	result = ''
	for i in words:
		result += i + ' '
	return result.strip()


def smash(words):
	res = ''
	for i in range(len(words)):
		res += words[i]
		if i < len(words) - 1:
			res += ' '
	return res


def smash(words):
	sentence = ''
	for i in words:
		if words[0] == i:
			sentence += i
		else:
			sentence += f' {i}'
	return sentence


def smash(words):
	result = ''
	for w in words:
		result += w + ' '
	return result.strip()


def smash(words):
	return ''.join((i + ' ' if len(words) - 1 != n else i for (n, i) in enumerate(words)))


def smash(words):
	t = ''
	for x in words:
		t = t + ''.join(x)
		if x != words[-1]:
			t += ' '
	return t


def smash(words):
	x = []
	if words == []:
		return ''
	else:
		for i in range(len(words) - 1):
			x.append(words[i] + ' ')
		x.append(words[len(words) - 1])
		return ''.join(x)


def smash(words):
	return ' '.join((wor for wor in words))


def smash(words):
	x = 0
	y = ''
	for elem in words:
		while x < len(words):
			y += words[x] + ' '
			x += 1
	return y[0:-1]


def smash(words):
	sen = ''
	for word in words:
		sen += word + ' '
	sen = sen.strip()
	return sen


def smash(words):
	x = ''
	for i in range(len(words)):
		x = x + words[i] + ' '
	x = x[:-1]
	print(x)
	return x


def smash(words):
	if words == []:
		return ''
	else:
		frase = words[0]
		for word in words[1:]:
			frase = frase + ' ' + word
		return frase


def smash(words):
	ans = ''
	for w in words:
		ans = ans + ' ' + w
	return ans.strip()


def smash(words):
	satz = ' '.join(words)
	return satz


def smash(words):
	tg = ' '.join(words)
	return tg.strip()


def smash(words):
	s = ''
	for x in words:
		s = s + x + ' '
	return s[:-1]


def smash(words):
	sentence = ' '.join(words)
	return sentence.strip()


def smash(w):
	result = ''
	for i in w:
		result += i + ' '
	return result.rstrip()


def smash(words):
	a = ''
	for i in range(len(words)):
		a += words[i] + ' '
	return a[:-1]


def smash(words):
	phrase = ''
	for i in words:
		phrase = phrase + i + ' '
	return phrase.rstrip()


def smash(words):
	return ' '.join(words)
print(smash(['Hello', 'World']))


def smash(words):
	result = ''
	for i in range(len(words)):
		if i < len(words) - 1:
			result += words[i] + ' '
		else:
			result += words[i]
	return result


def smash(words):
	w = ' '
	return w.join(words)


def smash(words):
	string = ''
	for item in words:
		string += item + ' '
	return string.strip()


def smash(arr):
	emptystring = ''
	for eachword in arr:
		emptystring = emptystring + eachword + ' '
	emptystring = emptystring.rstrip()
	return emptystring


def smash(words):
	string = ''
	for i in range(len(words)):
		if i == 0:
			string += words[0]
		else:
			string += ' ' + words[i]
	return string


def smash(words):
	if len(words) > 1:
		return ' '.join(words)
	return ' '.join(words)


def smash(words):
	return ''.join((word + ' ' for word in words)).strip()


def smash(words):
	output = ''
	for word in words:
		output += word
		output += ' '
	return output[:-1]


def smash(words):
	temp = ''
	for i in words:
		temp += i + ' '
	return temp.strip()


def smash(words):
	x = ''
	for i in words:
		x += i
		x += ' '
	return x.strip()


def smash(words):
	out = ''
	if len(words) == 0:
		return ''
	for word in words:
		out += word + ' '
	return out[0:-1]


def smash(words):
	string = ''
	for i in range(len(words)):
		string += words[i] + ' '
	string = string[:-1]
	return string


def smash(words):
	return ' '.join((char for char in words))


def smash(words):
	s = ''
	for c in words:
		s += ' ' + str(c)
	return s.strip()


def smash(words):
	salida = ' '.join(words)
	return salida


def smash(words):
	count = 0
	sentence = ''
	for word in words:
		sentence += word
		if count != len(words) - 1:
			sentence += ' '
		count += 1
	return sentence


def smash(words):
	newWords = ''
	for letters in words:
		newWords += letters
		if letters != words[-1]:
			newWords += ' '
	return newWords


def smash(words):
	newword = ''
	for word in words:
		newword += word + ' '
	return newword.strip()


def smash(words):
	string = ''
	for x in words:
		string += x + ' '
	return string[:-1]


def smash(words):
	for i in words:
		sentence = ' '.join(words)
		return sentence
	else:
		return ''


def smash(words):
	res = ' '.join([i for i in words])
	return res


def smash(words):
	stroke = ''
	for i in words:
		stroke = stroke + i + ' '
	stroke = stroke.rstrip()
	return stroke


def smash(words):
	output = ''
	for (idx, w) in enumerate(words):
		output = output + ' ' + words[idx]
	output = output.strip()
	return output


def smash(words):
	my_str = ''
	for x in words:
		if x != words[-1]:
			my_str += x + ' '
		else:
			my_str += x
	return my_str


def smash(words):
	string = ''.join([str(i) + ' ' for i in words])
	return string[:-1]


def smash(words):
	l = ''
	l = ' '.join(words)
	return l


def smash(words):
	s = ' '.join((word for word in words))
	return s


def smash(words):
	text = ''
	for i in words:
		text += i
		if i != words[-1]:
			text += ' '
	return text


def smash(words):
	w = ''
	for i in words:
		w += i + ' '
	return w[:-1]


def smash(words):
	c = ''
	for i in words:
		c = c + ' ' + ''.join(i)
	return c.lstrip()


smash = lambda a: ' '.join(a)


smash = lambda words: ' '.join((x for x in words)).strip()


def smash(words):
	return ' '.join((e for e in words))


def smash(words):
	s = ''
	for w in words:
		s += str(w) + ' '
	s = s.rstrip()
	return s


def smash(words):
	ans = ''
	for x in words:
		ans += x
		ans += ' '
	return ans[:-1]


def smash(words):
	sayac = len(words)
	yazi = ''
	for kelime in words:
		yazi += kelime
		sayac -= 1
		if sayac == 0:
			break
		yazi += ' '
	return yazi


def smash(words):
	sen = ''
	for i in words:
		sen += i + ' '
	return sen[:-1]


def smash(words):
	a = ''
	for (c, i) in enumerate(words):
		if c == len(words) - 1:
			a += i
		else:
			a += i + ' '
	return a


def smash(words):
	return ' '.join((elem for elem in words))


def smash(words):
	s = ' '
	r = ''
	for i in range(len(words)):
		if i == len(words) - 1:
			r = r + words[i]
		else:
			r = r + words[i] + s
	return r


def smash(words):
	new_str = ''
	for i in words:
		new_str = new_str + i + ' '
	return new_str[0:-1]


def smash(words):
	res = ''
	if len(words) == 1:
		for i in words:
			res = res + i
		return res
	else:
		for i in words:
			res = res + ' ' + i
		return res[1:]


smash = lambda n: ' '.join(n)


def smash(words):
	if words == []:
		return ''
	else:
		i = 1
		word = words[0]
		while i < len(words):
			word = word + ' ' + words[i]
			i += 1
		return word


def smash(words):
	sentens = ''
	for i in words:
		sentens += i + ' '
	return sentens[:-1]


def smash(words):
	ans = ' '.join(words)
	return ans


def smash(words):
	if len(words) != 0:
		a = ' '.join(words)
		return a
	elif len(words) == 1:
		a = words[0]
		return a
	else:
		a = ''
		return a


def smash(words):
	sentence = ''
	length_words = len(words)
	for word in words:
		sentence += word
		if word == words[-1]:
			pass
		else:
			sentence += ' '
	return sentence


def smash(words):
	return ''.join((word + ' ' for word in words))[:-1]