Answer the question
In order to leave comments, you need to log in
How to create a condition?
I am making a calculator and it is necessary to make a condition if the variable B>1, then to the value +100 +200 +300.
Simply put, the delivery slider, the first kilometer is 2500 rubles, the subsequent +100 rubles.
Answer the question
In order to leave comments, you need to log in
(A * 4500) + (B + 2500) + result()
function result() {
if (B > 1) {
B + 100
} else {
B + 0
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question