Be concise.
Be useful.
All contributions dictatorially edited by webmasters to match personal tastes.
Please do not paste any copyright violating material.
Please try to avoid dependencies to third-party libraries and frameworks.
(type x)
System.Console.WriteLine( x.GetType() );
print(x.runtimeType);
[{_, type} | _] = IEx.Info.info(x)
type
fmt.Printf("%T", x)
console.log (x == null ? x + '' : x.constructor.name);
console.log(typeof x);
System.out.println(((Object)x).getClass().getName());
println(x::class.simpleName)
(describe x)
print(type(x))
echo is_object($x) ? get_class($x) : gettype($x);
{$mode objfpc}{$H+}
{$ModeSwitch ImplicitFunctionSpecialization }
generic procedure PrintTypeOfX<T>(const X: T);
var
tk: TTypeKind;
begin
tk := System.GetTypeKind(X);
writeln(tk);
end;
print ref($x)||"SCALAR", "\n";
print(x.__class__)
print(type(x))
puts x.class