Convert boolean values to strings 'Yes' or 'No'.

Complete the bool_to_word (JavascriptboolToWord ) method.

Given: a boolean value

Return: a 'Yes' string for true and a 'No' string for false

using System;
using System.Linq;

public static class Kata
{
  public static string boolToWord(bool word)
  {
    //TODO
    if(word)
    {
      return "Yes";
    }
    else
    {
      return "No";
    }
  }
}

 

相关文章:

  • 2021-09-28
  • 2021-06-18
  • 2022-01-29
  • 2021-06-02
  • 2021-09-23
  • 2021-10-17
  • 2022-12-23
猜你喜欢
  • 2021-09-03
  • 2021-12-04
  • 2021-08-25
  • 2022-12-23
  • 2021-10-22
  • 2021-09-03
  • 2022-12-23
相关资源
相似解决方案