what's up with these bytes?

I'm trying to manipulate a byte in the WiiChuck demo program for the wiiChuck that's on todbot.com (I'm sure many are familiar with it).

The specific code that confuses me is this-

zbut = nunchuck_zbutton();
Serial.print("\tzbut: "); Serial.print((byte)zbut,DEC);

that code keeps looping around and it'll output in the serial monitor that zbut = 1 if it's held down, or a 0 if it's not.

first question: 'zbut' is not declared previously, the first instance is as shown here where it's set equal to nunchuck_zbutton(). Why is that? I would think we'd have to declare a data type before we just go stuffing something into a variable...

second question: Serial.print((byte)zbut,DEC);... why does it have to say 'byte' there?

third question: DEC... what's that mean?

fourth question (and the main one): I'm trying to make it so when I push the Z button once, it toggles whether or not sensor data from the accelerometer is being used. My code looks like this:

if ((byte)zbut = HIGH)
    {
      if (zButtonToggle = 1)
      {
        zButtonToggle = 0;
      }
      else
      {
        zButtonToggle = 1; 
      }
    }

but I'm purely guessing on the condition of that first if() statement. I've tried just putting (zbut = 1) or (zbut = high) but nothing. I'm outputting zButtonToggle and watching it in the Serial Monitor along with zbut, and zbut works fine, but zButtonToggle does nothing. I'd sure appreciate it if someone could explain to me why that is. Thanks.

Did the sketch compile?
If yes, then 'zbut' was declared.

'DEC' means print in decimal (it's in the documentation of 'print')
(byte) means cast whatever type "zbut" happens to be to force it into a "byte" (unsigned char) type.

4th question

if (zButtonToggle = 1)

The assignment of 1 to zButtonToggle is always true, because 1 is non-zero.
Try the equivalence operator "==" instead of the assignment operator.

Oh yeah, the "==" versus just "="... If I had a dollar for every time I forgot that, I'd be loaded.

And thanks for the explanation on that other stuff.

I was about to post that it still didn't work, but there was another of those dang assignment operators in there that needed to be an equivalence operator. Snap. It works now. Thanks.