The objective of this Kata is to write a function that creates a dictionary of factors for a range of numbers.

The key for each list in the dictionary should be the number. The list associated with each key should possess the factors for the number.

If a number possesses no factors (only 1 and the number itself), the list for the key should be `['None']`

The function possesses two arguments (`n` and `m`). Where `n` is the starting number and `m` is the ending number.

For example: All factors for 2 (`n`) through to 6 (`m`) with the number being the key in the dictionary:

```python
{2: ['None'], 3: ['None'], 4: [2], 5: ['None'], 6: [2, 3]}
```

Difficulty: introductory

Starter code:

def factorsRange(n, m):
	

Solutions:
def factorsRange(n, m):
    return {i: [j for j in range(2, i) if i % j == 0] or ['None'] for i in range(n, m + 1)}

def factorsRange(n, m):
    res = {}
    
    for num in range(n, m+1):
        factors = []
        
        for div in range(2, num // 2 + 1):
            if num % div == 0:
                factors.append(div)
        
        if len(factors) == 0:
            factors = ['None']
        
        res[num] = factors
    
    return res

def factorsRange(n, m):
    def factors(n):
        ret = [i for i in range(2, n) if n % i == 0]
        if not ret: return ['None']
        return ret
    return {i:factors(i) for i in range(n, m + 1)}

def factorsRange(n, m):
    i, dict = 2, {}
    for num in range(n, m + 1):
        while i < num:
            if num % i == 0 and num != i:
                dict.setdefault(num, []).append(i)
            i += 1
        i = 2
        if num not in dict:
            dict[num] = ['None']
    
    return dict

LIMIT = 351
memo = [[] for _ in range(LIMIT)]
for x in range(2, LIMIT):
    if not memo[x]:
        memo[x] = ['None']
    for y in range(2*x, LIMIT, x):
        memo[y].append(x)

def factorsRange(n, m):
    return {i:memo[i] for i in range(n, m+1)}

from collections import Counter

def factors(n):
    result = set()
    for i in range(2, int(n**0.5)+1):
        if n % i == 0:
            result.add(i)
            result.add(n // i)
    return sorted(result) if result else ['None']
    
def factorsRange(n, m):
    return {i: factors(i) for i in range(n, m+1)}

def factorsRange(n, m):
    return { e:([i for i in range(2,round(e/2)+1) if not e%i ] or ['None'] ) for e in range(n, m+1) }

factorsRange=lambda n,m:{x:sorted(set(__import__("itertools").chain(*((y,x/y)for y in range(2,int(x**.5)+1)if not x%y))))or['None']for x in range(n,m+1)}

factorsRange=lambda a,b:{n:[d for d in range(2,n)if not n%d]or['None']for n in range(a,b+1)}

def factorsRange(n, m):
    dlist = {}
    for x in range(n, m + 1):
        templist = []
        for y in range(2, x+1):
            if x % y == 0 and x != y:
                if templist.count(y) == 0: 
                    templist.append(y)
        if len(templist) >= 1:
            dlist.update({x : templist})
        else:
            dlist.update({x : ["None"]})
    return dlist