Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Square routes in variables

Author
Message
Keemo1000
19
Years of Service
User Offline
Joined: 26th May 2005
Location: 28th Dimension
Posted: 21st Jun 2005 21:29
Variables can be like :

a = 2 + 4
print a =
wait key

or

a = 2 * 4
print a
wait key

or

a = 2 / 4
print a
wait key

but is there a sign like ( * or / or + or -) for square routes ?

a = ? of 25
print a
wait key
(im looking for the ? sign)

pls reply---
IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 21st Jun 2005 21:36
There is no operator (or sign if you prefer) for square roots, but there is a function.

a = sqrt( a )

If you want any root, then you can raise the number you want the root of to 1/power ...

a = a ^ 0.5 : ` will give square root
a = a ^ 0.33333333333333 : ` will give cube root

*** Coming soon - Network Plug-in - Check my site for info ***
For free Plug-ins and source code http://www.matrix1.demon.co.uk
Peter H
20
Years of Service
User Offline
Joined: 20th Feb 2004
Location: Witness Protection Program
Posted: 22nd Jun 2005 02:08
Quote: "a = a ^ 0.33333333333333 : ` will give cube root
"

not to sound like a terd but you might want to do
instead

"We make the worst games in the universe."

IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 22nd Jun 2005 06:12
It really doesn't matter that much ...

You pay the price in speed, I pay the price in a little inaccuracy, but at the 7th or 8th significant digit, who cares?

*** Coming soon - Network Plug-in - Check my site for info ***
For free Plug-ins and source code http://www.matrix1.demon.co.uk
Keaz
21
Years of Service
User Offline
Joined: 22nd Sep 2003
Location: Somewhere in south Texas
Posted: 22nd Jun 2005 08:40
I will when my 1 pixel in a million is out of place.

Breaking Stuff=Fun!,Bug Testing<>Fun!, Bug Testing=Breaking Stuff, so...
Bug Testing=Fun! Hmmmm....
DOES NOT COMPUTE! SYSTEM MALFUNTION!
Keemo1000
19
Years of Service
User Offline
Joined: 26th May 2005
Location: 28th Dimension
Posted: 22nd Jun 2005 14:37
lol

pls reply---

Login to post a reply

Server time is: 2024-09-23 21:24:05
Your offset time is: 2024-09-23 21:24:05