The env.log host

What log does.

What log does: the playground prints the i32.

Goal

Log 12 then a city string.

@external("env", "log")
declare function log(n: i32): void;

@external("env", "logStr")
declare function logStr(s: string): void;

export function main(): void {
  log(12);
  logStr("host prints this");
}
@external("env", "log")
declare function log(n: i32): void;

@external("env", "logStr")
declare function logStr(s: string): void;

export function main(): void {
  log(0);
  log(1);
}
@external("env", "log")
declare function log(n: i32): void;

@external("env", "logStr")
declare function logStr(s: string): void;

export function main(): void {
  logStr("Nairobi");
}
@external("env", "log")
declare function log(n: i32): void;

@external("env", "logStr")
declare function logStr(s: string): void;

export function main(): void {
  log(480);
}