input in Prolog, read, end_of_file, get, get_byte, getc, flush_output
Input in Prolog is not always needed, as often the query process provides all the input that is needed. If explicit input is required, a set of extra-logical built-in predicates is available. These include:

Example 1: Assume that input is coming from the user's workstation window and that procedure read_a_char is defined as:

read_a_char(C) :-
   write('Type: '), flush_output,
   get_byte(C).

Then you can do the following - note that 43 is the character code for the character +.

?- read_a_char(Ch).
Type: +
Ch = 43

See also atom_codes, for conversion of a string of numeric character codes to an atom composed of the characters represented by those character codes. For example, 102, 105, 100, and 111 are the numeric codes for the letters f, i, d, and o. atom_codes can be used as follows:

?- atom_codes(A, [102, 105, 100, 111]).
A = fido

Example 2: Assume that there is a file called inputdata, which contains on its first line the term
likes(mary, pizza).
with a full stop at the end of the term.

?- see('inputdata'), read(Term), seen.
Term = likes(mary, pizza)

NB: No full stop at the end of Term's binding.