Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In this example the function determines if the value is greater than 50 it will append '19' to the front of the year, and '20' if not.

Code Block
 function myFunction(num)
{
  if (num.value > 50)
  {
  return "19" + String(num.value);
  }
  else
  {
  return "20" + String(num.value);
  }
}

...