im having a problem with polar and nonpolar how can you tell the difference?

Two main points to look for.

1. electronegativity (EN) of the atoms.
2. the shape of the molecule; i.e., is it symmetrical.

Look at the EN of the two atoms. A difference in EN means that BOND is polar. If its a diatomic molecule then the MOLECULE is polar. Examples: HCl, HF, HBr, HI, CO, etc.
If it ISN'T a diatomic molecule, then you must ALSO consider the shape to see if it is symmetrical. For example, CO2 is not a polar molecule because it is a linear molecule in space. O=C=O. The O=C bond on the left is polar and the C=O bond on the right is polar (because there is a difference in the EN of O and C) BUT the molecule as a whole is not polar becuse it is symmetrical and the two O atoms are pulling opposite ways and that cancels out. That is to say that the O on the left has a higher EN than C and the elctrons are pulled closer to it. The O on the right also has a higher EN than C and electrons are pulled closer to it. The electrons are pulling in opposite directions, the polarity cancels and the molecule is not polar. In fact, that is one way we know the CO2 molecule is linear. If it were some other shape it would have a dipole moment; since it does not we know it is linear. CH4 has four polar bonds (4 C-H bonds) but the molecule is tetrahedral in space and the polarity of the individual bonds cancel so the molecule as a whole has no dipole moment. NH4^+ is another example just like CH4. However, NH3 has a dipole moment. Each N-H bond is polar but the shape in space is not symmetrical. Why?
The three H atoms are directed more or less to the three corners of a tetrahedron BUT the fourth side, where the other H is in NH4^+ has a pair of electrons just sitting there. Unsymmetrical and the NH3 molecule has a dipole moment. H2O is another example, It has two H atoms attched but the other two sides of the O atom have unpaired electrons. Why is it not like CO2? Because we can measure a dipole moment for H2O so we KNOW is itsn't liner. A linear H2O molecule would NOT have a dipole moment. I hope this helps get you started on an understanding the difference. Look to see that there is a difference in EN, then look at the shape.