Is it ok to put script tags outside of the head tag? The same question goes for style tags.

I have done this and it works just fine but i'm wondering if this could bite me later since a book i have about javascript specificly sais i should put those tags in the head of the document.

I have my reasons for doing this.