* Streamlined the UDF