Return (and print) the first and last n elements / rows.
x (DataFrame, list, or array) – Input to summarize.
n (int) – Number of elements/rows to take from each end.
Combined head+tail of x, matching the input type.
x
DataFrame, list, or numpy.ndarray