Just to make sure. Is it a Floating point variable or a float variable?
The two are different.
A float, and double are floating point variables.
I believe float only covers like 5.23 and i believe uses a f at the end or something. 5.23f. I personally don't use them but i know of them.
So by the code of conduct rules i can't write this for you. I can help you with understanding the elements.
Also sorry about the soon be "treating you like a idiot" talk but i don't know what you know and it sounds like you jumped into this.
Might be better if you don't read but your still going to have to think what to do.
This does not contain code but i say "This divided by that is them times 3 equals gas"
Spoiler (click to show/hide):
Your likely going to need a place to save your gas while working with it. I would write a method for each test required by the program.
so basically your saying "gas times 3.784 is number of gasLiters. gas divided by 19.5 = oilBarrel .(note might be wrong when thinking in retro spec to your FYI) . gas times CO2.
give me time to think of the other one. but thats basically what their saying. I mean look at it this way.
1 gallon is equivalent to 3.7854 liters.
If your doing programming i would assume you have your math classes in order and you could figure out what L is if you gave G a value. That basically what your doing there
G = 3.7854L.