Archive for July, 2006
You are now browsing the archive for July in 2006.
Fibonacci is a number sequence which is recursively defined by:
F(n) = F(n-1) F(n-2)
You begin with the numbers 0 and 1, and continue by adding those together, getting a third number (1). Now, you add the last two numbers (1 and 1), and add the resulting number (2) in the stack as the fourth number in the Fibonacci sequence. Here is a Perl script for recursively calculating the Fibonacci sequence:
# The list in which the Fibonacci numbers will be stored
my @fibonacci = (0,1);
# The number on which to start calculating
my $n = 1;
# Repeat for the 1000 first Fibonacci numbers
while (@fibonacci < 1000) {
# Assign $n the sum of the last two Fibonacci numbers
$n = $fibonacci[@fibonacci - 1] $fibonacci[@fibonacci - 2];
# Push $n into the Fibonacci array
push @fibonacci, $n; # Add the result to the Fibonacci list
}
The 1000 first Fibonacci numbers will now be in the @fibonacci array. Calculating the Fibonacci numbers this way is very fast, and you can probably calculate a nigh-infinite number of elements in the Fibonacci sequence this way as long as Perl can handle a list of that size. Beware, though, that Perl might start rounding the numbers to infinity.of exam breast moviescript movie databaseclip movie art theatermovies columbus ohiompeg players moviemovie new chuckymovie noonerold titles movie Map
Although I and my previous blog, which was completely coded by me, shared certain bonds, I must say that the comfortability of WordPress is way, way more attractive than the pride in having written the blogging software myself. As soon as I read about pings and trackbacks, I realised that writing it all by myself would be too time-consuming. I just wanted to blog.
That’s when I looked up blogging software on Wikipedia, and studied the several choices. First WordPress actually caught my attention with its site’s clean and simple layout. When I once had tried it, there was no turning back: Everything was so simple.
Want a start for your new layout? Click on the Presentation tab in the administration panel and choose another one. Not satisfied by the supplied examples? Follow a handy hyperlink on that page to a huge layout database. There was something you didn’t like about the design? Well, the design consists only of four pages, and you can edit them directly through the online interface.
There’s a simple way for doing exactly everything.
A couple of days ago, I started a Swedish blog. The purpose of it was, just like the purpose of this one, to host and collect my various thoughts and projects. I don’t think that the niche market achieved by writing in a small language compensates the huge potential audience that English blogs have.
First, added an English section to my original blog. However, I realised that this solution was disadvantageous due to the uneven spread of PageRank along with other SEO problems. Therefore, I started this blog. As I said, it is supposed to collect my random thoughts, and so will probably not be updated very regularly.
Wish me luck.complaint loans amone unsecuredloans 5 1 mortgageloans 2 personal bankruptcyloan inc company acceptanceaffordable construction loanstudent loan collection agencyloan $5000 unsecuredloans 401k collateral Map
« Later Posts