# Very simple math

**URL:** <https://forum.kirupa.com/t/very-simple-math/178532>\
**Category:** Uncategorized\
**Created:** [February 11, 2006, 3:21pm UTC](https://forum.kirupa.com/t/very-simple-math/178532 "2006-02-11T15:21:38Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![johpoke](https://avatars.discourse-cdn.com/v4/letter/j/c0e974/32.png) [@johpoke](https://forum.kirupa.com/u/johpoke)\
**Post date:** [February 11, 2006, 3:21pm UTC](https://forum.kirupa.com/t/very-simple-math/178532/1 "2006-02-11T15:21:38Z")

</div>

I have a variuable with a number, loaded froma text file.

and i need to make it so that if i pust a button it (mathematicly) adds 1 to the variable, so that if w=6 then after button w=7. not w=61, which i keep getting…

its probably the same for flash mx, so if you know postie.

right now i have

on (release) {  
w = w+1;  
}

but tht adds “1” to the rest of the “6” = 61, not 7

/johannes
