Try stepping through it on VTI in the debugger, and you'll probably find your mistake fairly quickly. > Can anyone tell me why this code doesn't do what it's supposed to do? All it > does is go straight to "Number is prime." then adds some garbage to the > screen.......