It appears your Nissan Maxima failed the smog test because it did not pass the EVAP portion of the smog inspection. HC (Hydrocarbon) is close to failing, and might have something to due with the failed EVAP test, but it will only be certain after a hands-on diagnosis is conducted. HC is usually caused due to misfires, and rich or lean fuel conditions.
The EVAP test (also known as the Low Pressure Fuel Evaporative Test) ensures that there are no leaks between the vapor hose leading from the gas tank to charcoal canister, including the gas cap.
Here is how the EVAP system is tested: The LPFET involves the smog technician clamping the end of the hose leading to the charcoal canister and pressurize the gas tank with Nitrous Oxide via the LPFET test tool. The tool will then calculate the drop in pressure due to any leaks. There should be very little drop in pressure once the EVAP system (gas tank) is pressurized.
The fix involves locating the leak and repair the vapor hose, or component which is leaking. Depending on where the leak is located, this repair may be cheap or expensive, but the first step is to find where the leak is at.
The gas cap test is conducted on a separate test machine which is attached to the smog check machine. The gas cap test is not part of the LPFET.