Osmistěn v krychli. About GeoGebra. Contact us: [email protected].
Could someone help me please? Everything seems good for me.
![Jehlan Jehlan](/uploads/1/2/5/6/125624500/898060768.jpg)
It says:
prog.pas(57,14) Error: Incompatible types: got 'Char' expected 'LongInt'prog.pas(66,4) Fatal: There were 1 errors compiling module, stopping
tomblutomblu
1 Answer
There are missing parentheses, write
if (i=1) and (status='A') then write('Nezadal jste žádné těleso.');
For more information read the section operator precedence rules in your manual or online help (e.g. Free Pascal). Without the parentheses the compiler interprets your expression as
i = (1 and status) = 'A'
and this will compute the bitwise-and of the integer 1 and the char status, which is not allowed.
gammatestergammatester91811 gold badge77 silver badges1212 bronze badges
Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.