Formula for Centigrade (C) temperatures to Fahrenheit (F) -
F = C * 9 / 5 + 32
Rule
Centigrade to Fahrenheit (c_to_f)F is C * 9 / 5 + 32
Program-
c_to_f(C,F) :-F is C * 9 / 5 + 32.
% here freezing point is less than 32 Fahrenheit
freezing (F) :-F =< 32.
Goal to find Fahrenheit temperature and freezing point
Output-