I am familiar with Windows programming, but totally new to *nix so I hope this isn't a stupid question... This program causes a segfault right where I put SEGFAULT. It prints out the first two cout's, doesn't give me a chance to enter any input, and then segfaults.
I don't know what was going on earlier, but now, everything works fine up until the segfault. It lets me input the two numbers and then crashes without printing done. Thanks for your help!
It seems a bit odd that you are reading in user values as the addresses for the arrays, but I don't think that alone would cause a segmentation fault. Simply setting the pointer to invalid memory shouldn't cause a problem like that.