Skip to content

Instantly share code, notes, and snippets.

@giorgianav
Created January 31, 2019 11:12
Show Gist options
  • Select an option

  • Save giorgianav/7c1b2201e0a70fbe2d3ff02ce781e14c to your computer and use it in GitHub Desktop.

Select an option

Save giorgianav/7c1b2201e0a70fbe2d3ff02ce781e14c to your computer and use it in GitHub Desktop.
#include <stdio.h>
int main () {
int a;
scanf (“%d”, &a);
if ((a & (a - 1)) == 0)
printf (“Numarul este putere a lui 2.”);
else
printf (“Numarul nu este putere a lui 2.”);
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment