<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def get_processes():
    '''returns process names owned by the user'''
    user = getpass.getuser()
    for proc in  psutil.process_iter():
        if proc.username() != user:
            continue
        pname = psutil.Process(proc.pid).name()
        if os.name == 'nt':
            pname = pname[:-4]          # removiing .exe from end
        yield pname