Exponents

Exponents

Anonymous
Not applicable
393 Views
5 Replies
Message 1 of 6

Exponents

Anonymous
Not applicable
Dim x As Double
Dim y As Double
Dim z As Double

x = -3
y = 2
z = 0
Debug.Print (x ^ 2) + (y ^ 2) + (z ^ 2)
Debug.Print (-3# ^ 2) + (2# ^ 2) + (0# ^ 2)

First line prints 13. Second prints 5.

What am I missing here??
--
Bobby C. Jones
www.AcadX.com
0 Likes
394 Views
5 Replies
Replies (5)
Message 2 of 6

Anonymous
Not applicable
Ron Allen hooked me up on the AUGI guilds. It's all about operator
precedents. Thanks anyway!
--
Bobby C. Jones
www.AcadX.com

"Bobby C. Jones" wrote in message
news:[email protected]...
> Dim x As Double
> Dim y As Double
> Dim z As Double
>
> x = -3
> y = 2
> z = 0
> Debug.Print (x ^ 2) + (y ^ 2) + (z ^ 2)
> Debug.Print (-3# ^ 2) + (2# ^ 2) + (0# ^ 2)
>
> First line prints 13. Second prints 5.
>
> What am I missing here??
> --
> Bobby C. Jones
> www.AcadX.com
>
>
0 Likes
Message 3 of 6

Anonymous
Not applicable
Presedents...it must be Friday
--
Bobby C. Jones
www.AcadX.com

"Bobby C. Jones" wrote in message
news:[email protected]...
> Ron Allen hooked me up on the AUGI guilds. It's all about operator
> precedents. Thanks anyway!
> --
> Bobby C. Jones
> www.AcadX.com
>
> "Bobby C. Jones" wrote in message
> news:[email protected]...
> > Dim x As Double
> > Dim y As Double
> > Dim z As Double
> >
> > x = -3
> > y = 2
> > z = 0
> > Debug.Print (x ^ 2) + (y ^ 2) + (z ^ 2)
> > Debug.Print (-3# ^ 2) + (2# ^ 2) + (0# ^ 2)
> >
> > First line prints 13. Second prints 5.
> >
> > What am I missing here??
> > --
> > Bobby C. Jones
> > www.AcadX.com
> >
> >
>
>
0 Likes
Message 4 of 6

Anonymous
Not applicable
precedents or presidents? 🙂

--
Ed
--

"Bobby C. Jones" wrote in message
news:[email protected]...
> Presedents...it must be Friday
> --
> Bobby C. Jones
> www.AcadX.com
>
> "Bobby C. Jones" wrote in message
> news:[email protected]...
> > Ron Allen hooked me up on the AUGI guilds. It's all about operator
> > precedents. Thanks anyway!
> > --
> > Bobby C. Jones
> > www.AcadX.com
> >
> > "Bobby C. Jones" wrote in message
> > news:[email protected]...
> > > Dim x As Double
> > > Dim y As Double
> > > Dim z As Double
> > >
> > > x = -3
> > > y = 2
> > > z = 0
> > > Debug.Print (x ^ 2) + (y ^ 2) + (z ^ 2)
> > > Debug.Print (-3# ^ 2) + (2# ^ 2) + (0# ^ 2)
> > >
> > > First line prints 13. Second prints 5.
> > >
> > > What am I missing here??
> > > --
> > > Bobby C. Jones
> > > www.AcadX.com
> > >
> > >
> >
> >
>
>
0 Likes
Message 5 of 6

Anonymous
Not applicable
presentsidists......

--
R. Robert Bell, MCSE
www.AcadX.com


"Ed Jobe" wrote in message
news:[email protected]...
| precedents or presidents? 🙂
|
| --
| Ed
| --
|
| "Bobby C. Jones" wrote in message
| news:[email protected]...
| > Presedents...it must be Friday
| > --
0 Likes
Message 6 of 6

Anonymous
Not applicable
easy for you to say!
--
Bobby C. Jones
www.AcadX.com

"R. Robert Bell" wrote in message
news:[email protected]...
> presentsidists......
>
> --
> R. Robert Bell, MCSE
> www.AcadX.com
>
>
> "Ed Jobe" wrote in message
> news:[email protected]...
> | precedents or presidents? 🙂
> |
> | --
> | Ed
> | --
> |
> | "Bobby C. Jones" wrote in message
> | news:[email protected]...
> | > Presedents...it must be Friday
> | > --
>
>
0 Likes