All this discussion seems tpo me that it makes the problem more difficult than it is. First of all, for example, in islamic calendar dates of some religious holidays are according to the lunar calendar and they change every day. So it seems not managable to hardcode the dates. I imagine that the easiest solution is this. Just download dates for an index from the stock exchange of the country in question. For US, it is SP500, for example. Since the stock exchange is closed for the holidays, there will not be dates for those days. Then use this "dates" dataset to calculate the business days between any two dates. This approach makes the need to have a list of the holidays redundant.
... View more