def last_child(self):
for field in self._astroid_fields[::-<NUM_LIT:1>]:<EOL><INDENT>attr = getattr(self, field)<EOL>if not attr:  <EOL><INDENT>continue<EOL><DEDENT>if isinstance(attr, (list, tuple)):<EOL><INDENT>return attr[-<NUM_LIT:1>]<EOL><DEDENT>return attr<EOL><DEDENT>return None<EOL>
An optimized version of list(get_children())[-1]

        :returns: The last child, or None if no children exist.
        :rtype: NodeNG or None