Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

php decrement variable

$var = 1;
// use value (1) THEN decrement by one
$var--;
// decrement by one THEN use value (0)
--$var;

// aside: decrement by custom amount (1 emulates the above)
$var -= 1;
$var -= $step;
 
PREVIOUS NEXT
Tagged: #php #decrement #variable
ADD COMMENT
Topic
Name
8+6 =