2 câu trả lời
uses crt;
var i,j:longint; s:string;
begin
clrscr;
write('S=');readln(s);
i:=length(s);
while s[i]<>' ' do
dec(i);
for j:=i+1 to length(s) do write(upcase(s[j]));
readln
end.
uses crt;
var s:string;
i:longint;
begin
clrscr;
readln(s);
for i:=length(s) downto 1 do
if s[i] in ['A'..'Z'] then
begin
write(s[i]);
break;
end;
readln;
end.