@Patelbb While it is perfectly fine to seek urgent help, you could also post better samples of what you have and want rather than a plain sentence leading to some ambiguity where it's a variable operand/constant operand and what and where to assign missing or leave missing as per your words
Anyways, first function is very convenient for you to use rather than char or substr if i understand your requirement
if first(strip(var))='U' then do whatever you want