Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Challenge | Functions
Introduction to Python

Challenge

Завдання

Your task is to create a function called is_positive that takes in a single argument, n. It should return:

  • 'positive' if n is greater than 0.
  • 'negative' if n is less than 0.
  • 'zero' if n is equal to zero.

Все було зрозуміло?

Секція 6. Розділ 6
toggle bottom row
course content

Зміст курсу

Introduction to Python

Challenge

Завдання

Your task is to create a function called is_positive that takes in a single argument, n. It should return:

  • 'positive' if n is greater than 0.
  • 'negative' if n is less than 0.
  • 'zero' if n is equal to zero.

Все було зрозуміло?

Секція 6. Розділ 6
toggle bottom row
some-alt