## The challenge

Given 2 strings, `a` and `b`, return a string of the form short+long+short, with the shorter string on the outside and the longer string on the inside. The strings will not be the same length, but they may be empty ( length `` ).

For example:

 ``````1 2 `````` ``````solution("1", "22") # returns "1221" solution("22", "1") # returns "1221" ``````

## The solution in Python code

Option 1:

 `````` 1 2 3 4 5 6 7 8 9 10 11 `````` ``````def solution(a, b): if a.isdigit(): if a

Option 2:

 ``````1 2 `````` ``````def solution(a, b): return a+b+a if len(a)

Option 3:

 ``````1 2 `````` ``````def solution(a, b): return '{0}{1}{0}'.format(*sorted((a, b), key=len)) ``````

## Test cases to validate our solution

 `````` 1 2 3 4 5 6 7 8 9 10 11 `````` ``````import test from solution import solution @test.describe("Fixed Tests") def fixed_tests(): @test.it('Basic Test Cases') def basic_test_cases(): test.assert_equals(solution('45', '1'), '1451') test.assert_equals(solution('13', '200'), '1320013') test.assert_equals(solution('Soon', 'Me'), 'MeSoonMe') test.assert_equals(solution('U', 'False'), 'UFalseU') ``````