MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/lua/comments/1m2ec20/did_my_first_bit_of_lua_programming/n3o8kme/?context=3
r/lua • u/[deleted] • Jul 17 '25
if there's any feedback you want to give or changes, do tell me so i can learn more
8 comments sorted by
View all comments
13
I think your math is off. You'd wanna do this:
local price = 100local taxrate = 0.05
local taxprice = (price*taxrate)
local answerprice = price + taxprice
3 u/[deleted] Jul 17 '25 ohh yeah, price should’ve been multiplied by taxrate
3
ohh yeah, price should’ve been multiplied by taxrate
View all comments
13
u/[deleted] Jul 17 '25
I think your math is off. You'd wanna do this:
local price = 100
local taxrate = 0.05
local taxprice = (price*taxrate)
local answerprice = price + taxprice