So I am trying to divide two variables that are type `long long`, `totalBytesWritten` and `totalBytesExpected`

Basically I am trying to figure out the percentage complete my file upload is and update the progressbar accordingly.
For example, I am sending 262144 of 1839948 bytes

But when I do `double progress = totalBytesWritten/totalBytesExpected` it gives me some unexpected numbers. When I NSLog progress I get only 0s and then finally 1.

Thanks!