In your printDetails function, the variable b is not initialised and when you try to use that variable to index through the auburn[b] and many other subsequent array it end up with the Seg Fault. Try initialize the b value to 0 or anything og your requirnment, things should work.

-ssharish