Two or Three

This is a simple check for whether a short list contains one of the values you care about. Write a function has23 that takes a list nums with exactly 2 numbers. Return True if at least one element is 2 or 3, otherwise return False.

Примеры

Ввод
[2, 5]
Вывод
True
Ввод
[4, 3]
Вывод
True
Ввод
[4, 5]
Вывод
False

Нужно реализовать

def has23(nums: list[int]) -> bool:

Теги

listsarray
PostgreSQLv16

Taispeánfar toradh do chóid anseo

Visible tests
1
Input
[2,5]
ExpectedTrue
2
Input
[4,3]
ExpectedTrue
3
Input
[4,5]
ExpectedFalse
4
Input
[2,3]
ExpectedTrue
5
Input
[1,1]
ExpectedFalse
6
Input
[2,2]
ExpectedTrue
Focus radio
Paused · SomaFM · Fluid