# _CP_date

_CP_date is equivalent to the `*result* = date()` BASIC statement.

## Syntax

```
int _CP_date(int* result)
```

## Description

This function returns -1 if
an error occurs. The error code is contained in _CP_errno.

## Example(s)

```
/* Prints the numeric date */

int i;

_CP_date(&i);
_CP_unix_env();
printf("%d\n",i);
```

## See also

- [C functions overview](https://d3codex.com/cfunctions/c-functions-overview/)

---
Source: https://d3codex.com/cfunctions/cp-date/ - part of the D3Codex reference.
