# Adding log functions with different bases in dating

### Math Forum - Ask Dr. Math Time complexity describes the amount of the time an algorithm will take to execute.

### INTCK and INTNX: Two essential functions for computing intervals between dates in SAS - The DO Loop

There are different algorithms for searching an item in a list of an array, for example, Bubble sort, Quick sort, Merge sort, Binary Sort, etc. Every algorithm has different efficiency in terms of its time complexity.

To understand, consider an example, we have a sorted array, Now, we want to search the number 18, from the array of the given number. Array Pointer This algorithm follows the divide and rule methodology, where it divides the set equally at each step of iteration and searches for the item when it finds the item, the loops iteration gets terminated and returns the value. Number 18, was found at position 9, and it took 4 steps to search the item using the binary search algorithm. Suppose, we are provided with a list that contains the total number of items, and to search an item from these items we are using the Binary search algorithm.

LibreOffice Base (60) Add Current Date

Now, we have to find how many step it will take to find an item from the given items. The LOG formula will be: LOG functions are also widely used in economics, for stock price indexing graphs, and these graphs are very useful to check the prices going down or up. Options to compute anniversary dates Both functions support many options to modify the default behavior. If you want to count full year intervals, instead of the number of times people celebrated New Year's Eve, these function support options as of SAS 9. In other words, it returns the date value for 30APR The beauty of these functions is that they automatically handle leap years! If you request the number of days between two dates, the INTCK function includes leap days in the result. If an event occurs on a leap day, and you ask the INTNX function for the next anniversary of that event, you will get 28FEB of the next year, which is the most common convention for handling anniversaries of a leap day. An algorithm to compute years and days between events The following algorithm computes the number of years and days between dates in SAS: Use the INTNX function to find a third date the anniversary date which is the same month and day as the start date, but occurs less than one year prior to the end date.

The following DATA step computes the time interval in years and days between the first few US presidential inaugurations and deaths.