Virtually Shocking Main Header Image

Calculating Large Numbers in C

April 3rd, 2008 · No Comments

As a corollary to my last post, it’s important to be careful when calculating file seek positions (if you’re skipping around that way). It turns out it’s necessary to cast all of the numbers being used when calculating a seek position to a large integer, such as unsigned long int.

By the way, Rob had some helpful comments on that last post. (Thanks Rob!)

Tags: Linux · Mac OS X · My Code · Tech · Tools of the Trade

0 responses so far ↓

  • There are no comments yet...Kick things off by filling out the form below.

Leave a Comment