export dhcp lease with only hostname

can i get via terminal ip address of hostname only?

part of my script is

ip dhcp-server lease print file=$n

but this give me all dhcp lease addresses. can I find somehow ip of hostname=“pc”?
My all devices have all the same hostname, and i need all ip addresses for all pc’s.

If I understood correctly, this is what you need.

/ip dhcp-server lease print where hostname=“pc” file=$n