在pascal中,如何将string-var转换为某些char-var?例如:
var Name:string;
Arrayname:array[1..10]of char;
...
Name:='wow'; { I know that I write no sense things, I invent }
Arrayname[1]:=chr[1]of name; { this command roght now ! }
...
答案 0 :(得分:1)
我找到了方法:
var name:string;
begin
name:='gallo';
write(name[1]);
然后输出为:
g
:)