diff options
author | Felipe Bañados Schwerter | 2022-10-24 17:33:02 +0000 |
---|---|---|
committer | Felipe Bañados Schwerter | 2022-10-24 17:33:02 +0000 |
commit | ac7935ad693adac61f7fe0a6c9ec1344f3297c48 (patch) | |
tree | 09fc905c3ce091a76ea42c73e7a1890ae5292d8d | |
parent | bd22843d89bbf1966aca51f5b81f44f5d6766b1b (diff) |
Ok made it readable
-rw-r--r-- | entries/fbanados/fib.st | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/entries/fbanados/fib.st b/entries/fbanados/fib.st index 8431a09..099407c 100644 --- a/entries/fbanados/fib.st +++ b/entries/fbanados/fib.st @@ -1 +1,8 @@ -'From Pharo10.0.0 of 15 June 2022 [Build information: Pharo-10.0.0+build.521.sha.14f541319d443f4261f84f4fa19fbb34460a5edb (64 Bit)] on 24 October 2022 at 11:26:20.436554 am'!
!Integer methodsFor: '*Fibonacci' stamp: 'FelipeBanados 10/24/2022 11:13'!
fibonacciNumber
self <= 2 ifTrue: [ ^ 1 ].
^ (self - 1) fibonacciNumber + (self - 2) fibonacciNumber.! !
\ No newline at end of file +'From Pharo10.0.0 of 15 June 2022 [Build information: Pharo-10.0.0+build.521.sha.14f541319d443f4261f84f4fa19fbb34460a5edb (64 Bit)] on 24 October 2022 at 11:26:20.436554 am'! + +!Integer methodsFor: '*Fibonacci' stamp: 'FelipeBanados 10/24/2022 11:13'! +fibonacciNumber + self <= 2 ifTrue: [ ^ 1 ]. + ^ (self - 1) fibonacciNumber + (self - 2) fibonacciNumber. + +! ! |