$ ./guess_the_languageProblem Solving — fill the blank
Problem Solving — fill the blank · easy · #105

Complete the function

// returns "yes" if n is positive, otherwise "no"
function label(n: number): string {
  return n > 0 ____ "yes" : "no";
}

Answer: ? (also accepted: ?)

The ternary operator uses ? before the truthy branch.
Play Problem Solving ▸