Just draw them out and count each element up.
It's that easy.
I'm assuming you can't draw them, however, because you don't know nomenclature?
If you use/know proper IUPAC, you can draw the stick formula of any compound, simply by it's organic name.
Let's look at hexanoic acid. The ending, oic acid, means it's a carboxylic acid, R-COOH. Hexa- means R, the alkyl group (carbon chain) has 6 carbons, since hexa=6.
Therefore, when you put them together you get:
Which becomes C6H12O2
1-bromo-2-iodoethane is just halogens connected to ethane, a 2 carbon alkane.
ANE means alkane, the substance is saturated (meaning all single bonds).
ETH = 2 carbon chain
bromo = bromine
1-bromo means Carbon#1 is bonded to it, while 2-iodo means iodine is bonded to C#2.
Therefore your compound looks like this:
It's a trans molecule because of steric hindrence. The 2 halogens are large enough elements that they would bump into each other if on the same side of the molecule, so they have to be one on top, one on the bottom (trans).
This molecule becomes C2H4BrI.
alkyl group (R) # prefixes
meth(yl) = 1C...hex = 6C
eth(yl) = 2C......hept = 7C
prop = 3C.........oct = 8C
but = 4C...........non = 9C
pent = 5C.........dec(a) = 10C
There are a few prefixes beyond 10, but they are rarely used, so you don't have to worry about them.
Endings for different organic chemicals and the organic [Functional Structure]
Alkane ANE [R]
Alkene ENE double bonds present
Alkyne YNE triple bonds present
Alkyl Halides are R groups with halogens (like 1-bromo-2-iodoethane) [RX]
Alcohol OL ending, hydroxyl group (-OH) present [2 OH groups=DIOL, 3 OH groups = TRIOL] [ROH]
Aromatic (benzene ring) = [Ar]
Ether X Y ether (most ethers you name the 2 groups connected to the oxygen atom and add the word "ether", like methyl ethyl ether = CH2-O-CH2CH3) [ROR]
Epoxide a 3C ether ring, which is 2C combined with O in a cyclic ring. "Epoxy" is the PREFIX.
Ketone 2 alkyl groups connected by a carbonyl (C=O). Ending = -ONE [RCOR]
Aldehyde molecule with carbonyl+H on the end of it; ending is -AL, sometimes they simply use the word "aldehyde" [RCOH]
Carboxylic Acid alkyl group with COOH on 1 end; ending = -OIC ACID [RCOOH]
Ester alkyl group attached to a carboxylic acid, Without the H (COO-), where another alkyl group attaches to it. Ending is -ATE [RCOOR]
Amides combine a carbonyl (C=O) with NH2, they end in AMIDE. [RCONH2]
Amines are alkyl groups combined with NH2, and end in AMINE. [RNH2]
Nitriles are alkyl groups combined with cyano groups (C(triple bond)N); they end in NITRILE. [RCN]
This is probably more info than you need right now, but trust me, if you're taking orgo2, you're going to need it eventually! :)
Hope this helps!
If you can master IUPAC nomenclature, you can name and draw ANY molecule.