The abs filter returns the absolute value.
{% set number = -10 %}
{{ number|abs }}
{# output 10 #}
wartalab.blogspot.com is the best website and blog to provide tutorial for the, PHP, Drupal, Drupal 8 and general topic. Visit for programming knowledge and tutorial and solution
A number can be written in reverse order. For example 12345 = 54321 <?php $ num = 23456; $ revnum = 0; while ($ num > 1) { $...
No comments:
Post a Comment