75% means 75/100 or 0.75.Originally Posted bymohawk523

75% of a number N, is 0.75N

So if you take 75% form N you are left with N-0.75N=0.25N.

Your code should look something like:

price=0.25*price;

RonL

Results 1 to 3 of 3

- March 5th 2006, 01:37 AM #1

- Joined
- Mar 2006
- Posts
- 2

## % problem

Hi all

I hope someone may be able to help me as it includes a problem in programming so i may not be in the right place if not then sorry.

I want to - 75% from a number

eg Price = Price - 75%

With Price = 7 i get -68 when it should be 1.75.

Im sure this has something to do with the way i write the code and wondered if anyone has any idea how to do this in any programing language.

As i say i might be in wrong place but worth a try.

Thanks to all

- March 5th 2006, 01:46 AM #2

- Joined
- Nov 2005
- From
- someplace
- Posts
- 14,972
- Thanks
- 5

- March 5th 2006, 04:19 AM #3

- Joined
- Mar 2006
- Posts
- 2