HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Volumes > Chapter 3. Repetition structures > problem:


The power of 2

Volume problems

• Flowchart 1
• Flowchart 2
• Flowchart 3
• Sum until 0
• Sum less than N
• Sum of N numbers
• The power of 2
• 01. How many digits?
• 02. How many divisors?
• 04. Train
• 05. Factorial
• 06. X to the power of Y
• 07. Fibonacci Series
• 08. Binary to decimal
• 09. Decimal to binary

Feedback

If you notice incorrect translations in Contester, please let author know.

Time limit 2000/4000/4000/4000 ms. Memory limit 65000/65000/65000/65000 Kb.

Given a single integer N. Write a program that outputs YES if N is a power of 2, and NO otherwise.

standart input standart output
8
YES
22 NO

Для отправки решений необходимо выполнить вход.

www.contester.ru