CodeCogs - An iteractive open source Numerical library Welcome... Login
CodeCogs
shopping cart
OSXWindowsLinux
Search CodeCogs
Numerical Components

Valid RSS

UnitsDate

first Monday

Available under GPL (Free) and Commercial licence
get a GPL licence
COST (GBP)
this unit 1.17
sub units 0.00
add a commercial licence to your cart
0
viewed 1294 times and licensed 8 times

Returns the date in January when the first Monday occurs.

Controller: CodeCogs  Contact Controller
+View version details
Contents hide toc
buy now     get GPL     add to cart

Interface

#include <codecogs/units/date/firstmonday.h>

using namespace Units::Date;

int firstMonday (int year)[inline]
Returns the date in January when the first Monday occurs.
ExcelInteger cc_firstMonday (Integer year)
This function is available as a Microsoft Excel add-in.

Function Documentation

First Monday Calculator
  
Add calculator to website or email
 
intfirstMondayintyear )[inline]
Computes the number of days from the start of the year to the first Monday of the year (inclusive). This is the same as the date in January with the first Monday.
Example 1:
#include <stdio.h>
#include <codecogs/units/date/firstMonday.h>
using namespace Units::Date;
 
int main()
{
  for(int i=2000;i<2004;i++)
    printf("\n The first Monday in year %d is on the %d January", i, firstMonday(i));
  return 0;
}
Output:
The first Monday in year 2000 is on the 3 January
The first Monday in year 2001 is on the 1 January
The first Monday in year 2002 is on the 7 January
The first Monday in year 2003 is on the 6 January
Parameters:
yearcan be any integer greater than -4799.
Authors:
Will Bateman (Oct 2004)
Source Code:

To view or download source code you need either a GPL or Commercial Licence.

buy now     get GPL     add to cart

Not a member, then Register with CodeCogs. Already a Member, then Login.


Page Comments

Format Excel Equations

  You must login to leave a messge


Last Modified: 18 Oct 07 @ 17:07     Page Rendered: 2010-03-12 07:33:50

Valid CSS!   Valid XHTML 1.0 Transitional