Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I am teaching discrete math for computer science majors and I want some good examples of how mathematical induction is used to prove program correctness.

I have lots of experience with math induction but no experience with proofs of correctness so a few simple then harder examples would be nice.

Also, if you know any resources (books or papers) that talk about this that would be great.

share|improve this question
Guys on another site or rather this may have more idea. –  007resu Jan 14 '13 at 20:13
@Freddy, real programmers do no stinkin' proofs... Look for the books by Gries "A science of programming" or so. Dijkstra did prove most of his programs, but used a higly idiosincratic language and style. Be advised that this is hard going! –  vonbrand Jan 23 '13 at 2:09

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.