code: def _append_first_and_last(first, inner, last):
      if first is None:
          return _append_last(inner, last)
      if last is None:
          return _append_first(first, inner)
      return tf.concat(
          (
              tf.expand_dims(first, axis=-1),
              inner,
              tf.expand_dims(last, axis=-1),
          ),
          axis=-1,
      )
  
file_path: tf-quant-finance/tf_quant_finance/math/pde/steppers/parabolic_equation_stepper.py
imports: import tensorflow.compat.v2
  from tf_quant_finance import utils
label_desc: Use image node_id 11 for calling a global function with example usage: _append_first_and_last(first, inner, last) and returns: tf, _append_last, _append_first