HackerRank Python If-Else solution

preview_player
Показать описание
This video contains solution to HackerRank Python If-Else problem.But remember...before looking at the solution you need to try the problem at once for your logic building!
Рекомендации по теме
Комментарии
Автор

n = int(input().strip())
check = {True: "Not Weird", False: "Weird"}

print(check[
n%2==0 and (
n in range(2, 6) or
n > 20)
])

technicaldost
Автор

no this program is not correct hacker rank provide 2 cases but your solution is only for one cases please verify again in hacker rank website ...

technicaldost