<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def pwd(self, **kwargs):
 """ Returns the cwd Optional kwargs: node = <node> If specified, return only the directory name at depth <node>. """


            b_node  = False
            node    = 0
            for key,val in kwargs.items():
                if key == 'node':
                    b_node  = True
                    node    = int(val)

            str_path = self.cwd()
            if b_node:
                l_path      = str_path.split('/')
                if len(l_path) >= node+1:
                    str_path    = str_path.split('/')[node]
            return str_path