Integer comparison: Difference between revisions
Content added Content deleted
m (Changed over to works with template) |
(→{{header|Korn Shell}}: Corrected example (the old version had the same semantic, but didn't meet the task's requirements)) |
||
Line 265: | Line 265: | ||
if (( a < b )) ; then |
if (( a < b )) ; then |
||
printf "%d is less than %d\n" a b |
printf "%d is less than %d\n" a b |
||
fi |
|||
if (( a == b )) ; then |
|||
printf "%d is equal to %d\n" a b |
printf "%d is equal to %d\n" a b |
||
fi |
|||
if (( a > b )) ; then |
|||
printf "%d is greater than %d\n" a b |
printf "%d is greater than %d\n" a b |
||
fi |
fi |