| 1 |
# new_line(x): New Line Character |
| 2 |
|
| 3 |
New line character. |
| 4 |
|
| 5 |
## Declaration |
| 6 |
|
| 7 |
### Syntax |
| 8 |
|
| 9 |
```fortran |
| 10 |
retval = new_line(x) |
| 11 |
function new_line(c) |
| 12 |
``` |
| 13 |
|
| 14 |
### Arguments |
| 15 |
|
| 16 |
The input parameter `x` must be of type character. It can be a scalar or an |
| 17 |
array. |
| 18 |
|
| 19 |
### Return values |
| 20 |
|
| 21 |
The return value is a character of length one with the new line character |
| 22 |
appended of the same kind as of `x`. |
| 23 |
|
| 24 |
## Description |
| 25 |
|
| 26 |
**new_line(x)** returns the new line character. The return value is the ASCII |
| 27 |
newline character. |
| 28 |
|
| 29 |
## Types |
| 30 |
|
| 31 |
Supported input parameter types is character. |
| 32 |
|
| 33 |
```fortran |
| 34 |
function new_line(c) result(r) |
| 35 |
character(len=1), intent(in) :: c |
| 36 |
character(len=1) :: r |
| 37 |
end function |
| 38 |
``` |
| 39 |
|
| 40 |
## Examples |
| 41 |
|
| 42 |
```fortran |
| 43 |
program intrinsics_new_line |
| 44 |
implicit none |
| 45 |
print *, 'This is record 1.'//new_line('A')//'This is record 2.' |
| 46 |
end program |
| 47 |
``` |
| 48 |
|
| 49 |
**Result:** |
| 50 |
|
| 51 |
``` |
| 52 |
This is record 1.A |
| 53 |
This is record 2. |
| 54 |
``` |
| 55 |
|
| 56 |
## See Also |
| 57 |
|
| 58 |
None. |