user
Task

Demonstrate how to check whether the input device is a terminal or not.

Related task

* Check output device is a terminal
assistant
(formerly Perl 6)

**Works with**: Rakudo version 2015.12

```
say $*IN.t ?? "Input comes from tty." !! "Input doesn't come from tty.";

```

```
$ raku istty.raku
Input comes from tty.
$ true | raku istty.raku
Input doesn't come from tty.

```