Inspired by the development team at Vooza, write the function `howManyLightsabersDoYouOwn`/`how_many_light_sabers_do_you_own` that 

* accepts the name of a programmer, and
* returns the number of lightsabers owned by that person.

The only person who owns lightsabers is Zach, by the way. He owns 18, which is an awesome number of lightsabers. Anyone else owns 0.

```if:coffeescript,javascript,php,python,ruby,typescript
**Note**: your function should have a default parameter.
```

```c#
Kata.HowManyLightsabersDoYouOwn("Adam") == 0
Kata.HowManyLightsabersDoYouOwn("Zach") == 18
```
```python
how_many_light_sabers_do_you_own('Zach') == 18
how_many_light_sabers_do_you_own('Adam') == 0
how_many_light_sabers_do_you_own()       == 0
```

Difficulty: introductory

Starter code:

def how_many_light_sabers_do_you_own(*name):
	

Solutions:
def how_many_light_sabers_do_you_own(name=""):
    return (18 if name=="Zach" else 0)

how_many_light_sabers_do_you_own=lambda n='': 18 if n=='Zach' else 0

def how_many_light_sabers_do_you_own(name='haha'):
    return 18 if name=='Zach' else 0

def how_many_light_sabers_do_you_own(name=''):
    switch = {      
        'Zach':  18,
        }
    return switch.get(name, 0)

def how_many_light_sabers_do_you_own(name=""):
    if name == "Zach":
        return 18
    else:
        return 0

def how_many_light_sabers_do_you_own(name=False):
    return name == "Zach" and 18

how_many_light_sabers_do_you_own=lambda n=str():0x12.__mul__(sum(map(ord,n)).__eq__(0x186))

def how_many_light_sabers_do_you_own(name=""):
    
    return {'Zach': 18}.get(name,0)
    
     


def how_many_light_sabers_do_you_own(name='tigerk00'):
    return 18 if name == 'Zach' else 0

# Do your stuff here!
def how_many_light_sabers_do_you_own(name=''):
    if name == "Zach":
        return 18
    else: return 0

def how_many_light_sabers_do_you_own(name = "Brad"):
    if name == "Zach":
        lightsabers = 18
    else:
        lightsabers = 0   
    return lightsabers

def how_many_light_sabers_do_you_own(*name):
    if name != ():
        print(name)
        if name[0] == 'Zach':
            return 18
        return 0
    return 0

def how_many_light_sabers_do_you_own(*name):
    if len(name) == 0: return 0
    return 18 if name[0] == 'Zach' else 0

def how_many_light_sabers_do_you_own(name = "Someone"):
    return 18 if name == "Zach" else 0

def how_many_light_sabers_do_you_own(name = "x"):
    if name == 'Zach': return 18
    elif name == 'x': return 0
    else: return 0

def how_many_light_sabers_do_you_own(name=None):
    return name == "Zach" and 18

def how_many_light_sabers_do_you_own(name="john"):
    if name == "Zach":
        return 18
    else:
        return 0

def how_many_light_sabers_do_you_own(name="No one"):
    if name == "Zach":
        return 18
    else:
        return 0

def how_many_light_sabers_do_you_own(a=""):
    return 18 if a == "Zach" else 0

how_many_light_sabers_do_you_own = lambda *name: 18 if 'Zach' in name else 0

def how_many_light_sabers_do_you_own(that_person_is='someone else'): return 18 if that_person_is=="Zach" else 0

def how_many_light_sabers_do_you_own(name='Abc'):
    return 18 if name=='Zach' else 0

def how_many_light_sabers_do_you_own(name="l"):
    return 0 if name != "Zach" else 18

def how_many_light_sabers_do_you_own(name = 'ehhh'):
    return 18 if name =='Zach' else 0

def how_many_light_sabers_do_you_own(name=0):
    a = ['Zach']
    if name == a[0]:
        return 18
    else: return 0

def how_many_light_sabers_do_you_own(*name):
    try:
        return 18 if name[0]=='Zach' else 0
    except:
        return 0

def how_many_light_sabers_do_you_own(name=None):
    try:
        return 18 if name=='Zach'else 0
    except AttributeError:
        return 0

def how_many_light_sabers_do_you_own(name='James'):
    return 18 if name == 'Zach' else 0

import re

# Assigning default empty value if no name is entered.
# When not done, Exit code is non-zero with a TypeError - missing 1 required positional argument: 'name'
# if the function is called without argument.
def how_many_light_sabers_do_you_own(name=''):
    # Return 18 if you match Zach, in all other cases, return 0
    return 18 if re.match('^Zach$', name) else 0

def how_many_light_sabers_do_you_own(name=None):
    return 0 if not name else 18 if name == "Zach" else 0


def how_many_light_sabers_do_you_own(name="Levi"):

    if name == "Zach":
        return 18
    return 0


def how_many_light_sabers_do_you_own(name='null'):
    return 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(name="null"):
    try:
        if name=="Zach":
            return 18
        else:
            return 0
    except TypeError:
        return 0

def how_many_light_sabers_do_you_own(name = 'pete'):
    return 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(x = ""):
    return 0 if x != "Zach" else 18

def how_many_light_sabers_do_you_own(name = "Adam",lightsabers = 0):
    if name == "Zach":
        return 18
    else:
        return lightsabers


def how_many_light_sabers_do_you_own(name = "rex"):
    if name == "Zach":
        return 18
    else:
        return 0

def how_many_light_sabers_do_you_own(name = 'Jack'):
    return 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(name = 'notZach'):
    return 18 if name == 'Zach' else 0


def how_many_light_sabers_do_you_own(*name):
    res=list(name)
    try:
        return 18 if res[0]=="Zach" else 0
    except:
        return 0

def how_many_light_sabers_do_you_own(*args):
    
    if len(args) == 0:
        return 0
    
    return 18 if args[0] == 'Zach' else 0

def how_many_light_sabers_do_you_own(name=''):
    '''
    Inspired by the development team at Vooza, write the function
    
    howManyLightsabersDoYouOwn / how_many_light_sabers_do_you_own that
    
    - accepts the name of a programmer, nad
    - returns the number of lightsabers owned by that person.
    
    The only person who owns lightsavers is Zach, by the way.
    He owns 18, which is an awesome number of lightsabers.
    Anyone elese owns 0.
    '''
    if name == 'Zach':
        return 18
    return 0

def how_many_light_sabers_do_you_own(name = 'Joe'):
    return 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(name='no_name'):
    return 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(name="Jack"):
    if name == 'Zach':
        return 18
    else:
        return 0

def how_many_light_sabers_do_you_own(*name):
    try:
        name = list(name)
        if name is []:
            name.append("")
        
        return 18 if str(name[0]) == "Zach" else 0
    except:
        return 0

def how_many_light_sabers_do_you_own(*name):
    if len(name)>0:
        return 18 if name == ('Zach',) else 0
    else:
        return 0

def how_many_light_sabers_do_you_own(name = None):
    if not name:
        return 0
    return 18 if name == "Zach" else 0

def how_many_light_sabers_do_you_own(name = "George"):
    return 18 if name == "Zach" else 0

def how_many_light_sabers_do_you_own(name='Hugo'):
    return 18 if name=='Zach' else 0

def how_many_light_sabers_do_you_own(name='p'):
    return 18 if name=='Zach' else 0

def how_many_light_sabers_do_you_own(*name):
    return sum([18 if i == 'Zach' else 0 for i in name])

def how_many_light_sabers_do_you_own(name ="stam"):
    return 18 if name == "Zach" else 0

def how_many_light_sabers_do_you_own(name=''):
    if name == "Zach".capitalize():
        return 18
    else:
        return 0

def how_many_light_sabers_do_you_own(*name):
    return 0 if len(name) == 0 else 18 if name[0]=="Zach" else 0

def how_many_light_sabers_do_you_own(name = 0):
    d = {'Zach':18}
    return d.get(name,0)

def how_many_light_sabers_do_you_own(name='aring'):
    try:
        return 18 if name == 'Zach' else 0
        
    except:
        return 0


def how_many_light_sabers_do_you_own(name='kendall jenner'):
    if name == 'Zach':
        return 18
    else:
        return 0 

def how_many_light_sabers_do_you_own(name='s'):
    if name == "Zach":
        return 18
    else:
        return 0

# end goal - the function should return 18 lightsabers for Zach and 0 for anyone else
# use a ternary operator or simple if/else

# input - string, name
# output - integer
# edge cases - lower case names, invalid unittests 

# function that takes name argument
def how_many_light_sabers_do_you_own(name=''):
# if name is Zach
    if name == "Zach":
# return 18
        return 18
# else
    else:
# return 0
        return 0

def how_many_light_sabers_do_you_own(name="!"):
    return 18 if name=="Zach" else 0

def how_many_light_sabers_do_you_own(s=''):
#     if name == 'Zach':
#         return 18
#     return 0
    return s.count('Zach') * 18

def how_many_light_sabers_do_you_own(name="None"):
    return 18*int(name == "Zach")

def how_many_light_sabers_do_you_own(*args):
    if len(args) == 0:
        return 0
    if args[0] == 'Zach':
        return 18
    return 0

def how_many_light_sabers_do_you_own(*args, zach=18):
    return zach if "Zach" in args else 0

def how_many_light_sabers_do_you_own(name='a'):
    return {'Zach' : 18}.get(name, 0)

def how_many_light_sabers_do_you_own(name="Carlos"):
    if name == "Zach":
        return 18
    else:
        return 0

how_many_light_sabers_do_you_own = lambda name = 'zach': 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(*name):
    try: name
    except NameError:
        return 0
    else:
        if 'Zach' in name:
            return 18
        return 0

def how_many_light_sabers_do_you_own(name= 'abc'):
    return 18 if name == 'Zach' else 0

def how_many_light_sabers_do_you_own(name = 'xxx'):
    return 18 if name in'Zach' else 0

def how_many_light_sabers_do_you_own(name = 'Boob'):
    return [0, 18][name == 'Zach']

def how_many_light_sabers_do_you_own(n=0):  
  return 0 if n!='Zach' else 18

def how_many_light_sabers_do_you_own(name=""):
    if name == "Zach":
        return 18
    elif name == "":
        return 0
    else:
        return 0