Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ATTN: Tom Lake

5 views
Skip to first unread message

Geeza

unread,
Apr 3, 2008, 12:07:07 PM4/3/08
to
I tried it, but Freebasic wasn't having anything to do with it.

You might have to bear in mind, i'm only been using Freebasic for a short while and the fact i've not been programming too long. :)


--------------= Posted using GrabIt =----------------
------= Binary Usenet downloading made easy =---------
-= Get GrabIt for free from http://www.shemes.com/ =-

Tom Lake

unread,
Apr 3, 2008, 1:01:17 PM4/3/08
to

"Geeza" <a...@mouse.com> wrote in message news:AO6Jj.3945$8p4....@newsfet15.ams...

>I tried it, but Freebasic wasn't having anything to do with it.

I had -lang qb on the command line

Try this:

declare function gcd(x as single,y as single) as single
print gcd(112,144)
sleep

function gcd(x as single,y as single) as single
dim q as single, r as single
do
q=int(x/y)
r=x-q*y
x=y
y=r
loop until r<=0
gcd=x
end function


Tom Lake

unread,
Apr 3, 2008, 1:08:13 PM4/3/08
to

"Tom Lake" <tl...@twcny.rr.com> wrote in message news:ft32dh$evf$1...@aioe.org...


<rant> While I'm at it, the above requirement to declare all variables goes against
the
entire intention of BASIC. Find a copy of Back to BASIC by John Kemeny and
Tom Kurtz (the authors of BASIC) and you'll get a good feeling for what BASIC
is really supposed to be. </rant>

Tom Lake

0 new messages