determining type better