compare order, how to do?

i'm reciving data for the ardiuino uno, from de0 nano, i would like to know how can i compare a digital data that i recive, for example, i get 00110001 and i want the ardiuno to compare the data that you recieve and to match it with the code that i need to trigger that he will send a singal that would start the buzzer.

i would like to know how can i compare a digital data that i recive, for example, i get 00110001 and i want the ardiuno to compare the data that you recieve and to match it with the code

if (rxData == 0x31)
{
  doSomething ();
}

or

if (rxData == 0b00110001)
{
  doSomething ();
}

or

if (rxData == '1')
{
  doSomething ();
}

thank you for the first reply.
What will there be in rxData in arduino if I stop recieve data from the de0 nano?

No idea - your posts don't contain enough information to make a sensible reply.