Snake sheds can stretch up to 20 percent longer than the snakes actual body length so they're never a good choice for determining length. Two ways I know of accurately measuring snakes are by using a "squeeze box" or using a piece of string. A squeeze box is simply a big flat box with a clear lid filled with something like egg crate foam. You put the snake in the box, close the lid to squeeze it into the foam, thereby immobilizing it. You then trace out the snakes midline with either a transparency marker or a piece of string. Release the snake and then measure your marker line or piece of string. The other method using just a string is okay but often gives measurements that may be innaccurate by several cm.. In this method you simply hold a piece of string to the snakes body as it crawls through your hands, trying to keep the string tight to the snakes body the whole time. Like I said it's difficult and allows for considerable innaccuracy. You shouldn't end up being multiple feet/cm off in measurements, but still expect to be off somewhat.
Matt Campbell