Date created: 07/10/11 19:05:48. Last modified: 12/13/12 11:41:20
#!/bin/bash# Project Euler - Problem 2last=0this=1total=0while (($this<4000000))do f=`expr $this + $last` if [ `expr $f % 2` == 0 ] then total=`expr $total + $f` fi last=$this this=$fdoneecho $total
^ Top
Previous page: Problem 1 Next page: Problem 3