program CrossPlatformHelloWorld;
uses
FMX.Dialogs;
{$R *.res}
begin
ShowMessage('Hello world!');
end.
Most of the Delphi supported platforms (Win32/Win64/OSX32/Android32/iOS32/iOS64) also support a console so the WriteLn
example fits them well.
For the platforms that require a GUI (any iOS device and some Android devices), the above FireMonkey example works well.