# Maths trickkkkkWatch

Announcements
This discussion is closed.
#1
Hellooooooo!
is there anybody doin Maths or at least interested in it???
I got a maths trick (exactly this is for computing programmin')

Right: If you got a random number a (b,c,d,e,,,any number that you like)
How can you work out the number c so that a+c is a multiple of 10.

(in this case, you dunno the exact value of a)

Cumon everybody,Let's have some fun!
0
15 years ago
#2
c = 10-a?
0
15 years ago
#3
I think you need the ceiling function...

c = 10*ceiling(a/10)-a
0
15 years ago
#4
(Original post by JamesF)
c = 10-a?
how on earth did you come up with that?
0
15 years ago
#5
(Original post by mikesgt2)
I think you need the ceiling function...

c = 10*ceiling(a/10)-a
0
#6
''I think you need the ceiling function...

c = 10*ceiling(a/10)-a''

Hey Mikesgt2
Sorry but i never heard of this ceiling function.
(suppose that am one of the stupid guys)
0
15 years ago
#7
Since you mentioned programming, you might be interested that many programming libraries contain floor and ceiling functions.

in C: math.h
in C++: cmath
in Java: java.lang.Math
0
15 years ago
#8
(Original post by Jonny W)
Since you mentioned programming, you might be interested that many programming libraries contain floor and ceiling functions.

in C: math.h
in C++: cmath
in Java: java.lang.Math
I think you will find that very few languages do not include such functions.
0
#9
Hey guys!
i just found out the solutions.
in lesson now,
will be back and tell you later!
c you tonight
0
15 years ago
#10
huh?
0
#11
Right!
this is the solution
i have found it but, poor me still don't know how to prove it professionallllllyyy

substitute a is a random nature number
Step 1
a+9=b

Step2:
divide b by 10

Step3
take the first decimal number (some kind of 0.c) time 10= c

Step 4
d= 9-c is the value that need to add to a to make a mutiple of 10.

Example

a=197
b=197+9=206
b/10=20.6
c=0.6*10=6
d=9-6=3

(d+a=200:10)

that's it.
0
X
new posts

### 2,173

people online now

### 225,530

students helped last year
Latest
My Feed

### Oops, nobody has postedin the last few hours.

Why not re-start the conversation?

see more

### See more of what you like onThe Student Room

You can personalise what you see on TSR. Tell us a little about yourself to get started.

### University open days

• University of Dundee
Mon, 26 Aug '19
• University of Aberdeen
Tue, 27 Aug '19
• Norwich University of the Arts
Sat, 31 Aug '19

### Poll

Join the discussion

#### How are you feeling about GCSE Results Day?

Hopeful (209)
12.83%
Excited (144)
8.84%
Worried (295)
18.11%
Terrified (367)
22.53%
Meh (149)
9.15%
Confused (35)
2.15%
Putting on a brave face (223)
13.69%
Impatient (207)
12.71%