The last print statement is only reached when C is not the biggest number and they are not all equal. If you put the last print outside of the else clause it will get executed more often
PS: Check out what gets printed if A and B are some random but different numbers and C==0
PPS: You should always have a line 'use warnings;' in your code (right after '#!/usr/bin/perl'). It helps you with finding bugs (not this one though).
In reply to Re: Find the biggest number from three numbers
by jethro
in thread Find the biggest number from three numbers
by shrsv
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |