@Udf
  public String elt(
      @UdfParameter(description = "the nth element to extract") final int n,
      @UdfParameter(description = "the strings of which to extract the nth") final String... args
  ) {
    if (args == null) {
      return null;
    }
    if (n < 1 || n > args.length) {
      return null;
    }

    return args[n - 1];
  }
@Test
  public void shouldSelectFirstElementOfOne() {
    // When:
    final String el = elt.elt(1, "a");

    // Then:
    assertThat(el, equalTo("a"));
  }