I
I
impressive172016-04-17 23:52:32
Pascal
impressive17, 2016-04-17 23:52:32

Why is the value not incremented?(pascal)?

for some reason it gives an error: "The name of a procedure or function was expected." Here is the code:

program string8;
var string,rub,cur:string;
length,i:integer;
alfavit:array ['a'..'z'] of integer;
begin
readln(stroke);
rub:=copy(stroka,1,Pos('hi',stroka)-1);
length:=length(rub);
alphabet(stroka[1]):=alfavit(stroka[1]) + 1;
end.

How can I fix this? (thanks in advance)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey, 2016-04-18
@alsopub

Necessary:
alfavit[stroka[1]]:=alfavit[stroka[1]] + 1;

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question