implemented fibonacci in three ways