Given two strings, the first being a random string and the second being the same as the first, but with three added characters somewhere in the string (three same characters),

Write a function that returns the added character

### E.g

```
string1 = "hello"
string2 = "aaahello"

// => 'a'
```

The above is just an example; the characters could be anywhere in the string and string2 is actually **shuffled**.

### Another example

```
string1 = "abcde"
string2 = "2db2a2ec"

// => '2'
```

Note that the added character could also exist in the original string


```
string1 = "aabbcc"
string2 = "aacccbbcc"

// => 'c'
```

You can assume that string2 will aways be larger than string1, and there will always be three added characters in string2.

```if:c
Write the function `added_char()` that takes two strings and return the added character as described above.
```

```if:javascript
Write the function `addedChar()` that takes two strings and return the added character as described above.
```

Source: codewars | Difficulty: EASY
Tags: String algorithms

Starter code: def added_char(s1, s2):
	

Solutions:
from collections import Counter

def added_char(s1, s2):
	return next((Counter(s2) - Counter(s1)).elements())


def added_char(s1, s2):
	for i in s2:
		if s1.count(i) != s2.count(i):
			return i


from functools import reduce
from operator import xor

def added_char(s1, s2):
	return chr(reduce(xor, map(ord, s1), 0) ^ reduce(xor, map(ord, s2), 0))


from collections import Counter

def added_char(s1, s2):
	return list(Counter(s2) - Counter(s1))[0]


from collections import Counter

def added_char(s1, s2):
	return (Counter(s2) - Counter(s1)).popitem()[0]


def added_char(s1, s2):
	s2 = list(s2)
	[s2.remove(i) for i in s1]
	return s2[0]


from collections import Counter

def added_char(*args):
	(c1, c2) = map(Counter, args)
	return (c2 - c1).popitem()[0]


added_char = lambda s1, s2: next((i for i in s2 if s1.count(i) != s2.count(i)))


def added_char(s1, s2):
	return chr(int((sum((ord(x) for x in s2)) - sum((ord(x) for x in s1))) / 3))