In this Kata, you will write a function `doubles` that will remove double string characters that are adjacent to each other.

For example:

`doubles('abbcccdddda') = 'aca'`, because, from left to right:
```Haskell
a) There is only one 'a' on the left hand side, so it stays.
b) The 2 b's disappear because we are removing double characters that are adjacent. 
c) Of the 3 c's, we remove two. We are only removing doubles. 
d) The 4 d's all disappear, because we first remove the first double, and again we remove the second double.
e) There is only one 'a' at the end, so it stays.
```

Two more examples: `doubles('abbbzz') = 'ab'` and `doubles('abba') = ""`. In the second example, when we remove the b's in `'abba'`, the double `a` that results is then removed.

The strings will contain lowercase letters only. More examples in the test cases. 

Good luck!

Difficulty: EASY
Starter code: def doubles(s):
	

Solutions:
def doubles(s):
	cs = []
	for c in s:
		if cs and cs[-1] == c:
			cs.pop()
		else:
			cs.append(c)
	return ''.join(cs)


def doubles(s):
	for i in s:
		if i * 2 in s:
			s = s.replace(i * 2, '')
	return s


import re

def doubles(s):
	re_double = re.compile('(.)\\1')
	while re_double.search(s):
		s = re_double.sub('', s)
	return s


from itertools import groupby

def doubles(s):
	new_s = ''.join((char * (len(tuple(group)) % 2) for (char, group) in groupby(s)))
	return new_s if len(new_s) == len(s) else doubles(new_s)


def doubles(s):
	for x in range(0, 3):
		for a in 'abcdefghijklmnopqrstuvwqxyz':
			s = s.replace(2 * a, '')
	return s


def doubles(s):
	for _ in range(9):
		for i in set(s):
			s = s.replace(i + i, '')
	return s


def doubles(s):
	for _ in range(99):
		for (a, b) in zip(s, s[1:]):
			if a == b:
				s = s.replace(a + b, '')
				break
	return s


def doubles(s):
	chars = set(s)
	while True:
		token = s
		for c in chars:
			s = s.replace(c + c, '')
		if len(token) == len(s):
			break
	return s


import re

def doubles(s):
	while len(re.sub('([a-z])\\1', '', s)) != len(s):
		s = re.sub('([a-z])\\1', '', s)
	return s


from itertools import groupby

def check_double(s):
	return ''.join([x[0] for x in groupby(s) if len(list(x[1])) % 2 != 0])

def doubles(s):
	out = check_double(s)
	while out != check_double(out):
		out = check_double(out)
	return out