cloudll Posted October 1, 2011 Share Posted October 1, 2011 Hey guys, Say I have two variables, the first being $level_1 = '100'; and $level_2 = '1000'; is there anyway to work out the difference between the two and output it? Quote Link to comment https://forums.phpfreaks.com/topic/248211-finding-the-difference-between-two-variables/ Share on other sites More sharing options...
Drummin Posted October 1, 2011 Share Posted October 1, 2011 Simple math. $result=$level_2-$level_1; Quote Link to comment https://forums.phpfreaks.com/topic/248211-finding-the-difference-between-two-variables/#findComment-1274566 Share on other sites More sharing options...
cloudll Posted October 1, 2011 Author Share Posted October 1, 2011 oh that is simple, thanks Quote Link to comment https://forums.phpfreaks.com/topic/248211-finding-the-difference-between-two-variables/#findComment-1274576 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.