[Search tip detail and code files using keywords, tip number, author name, etc ]
 
    For tip to function correctly, you must ensure that the downloaded file name matches the file name
    displayed in the Rename File To field. Please rename downloaded files when necessary.
List Lookup Function
Tip# 3485 By Sanjay Kulkarni On 10-Sep-2010
4
Rated By 1 users Downloaded : 439
Categories : LISP Code Modules, Programming Examples
Software type : AutoCAD 2011
Rename File To : lstVlookUp.LSP
Find the smallest integer in the list that is larger than the first argument.

Sanjay Kulkarni has submitted a LISP function to perform a special function. Unlike most other tips you see here, this function is meant to be used as part of a larger routine. Sanjay's function requires two arguments: an integer and a list of integers in ascending order. When executed, it will return the smallest integer in the list that is larger than the first argument. For example, if you call this function with a first argument of 2 and this list (1 2 3 4 5), it will return the number 3. Sanjay does a great job of providing details of how the code works, and plenty of examples along with the code itself.

 

Average Rating:
4


User comments