fork(1) download
  1. #include <iostream>
  2.  
  3. int main()
  4. {
  5. using namespace std;
  6. unsigned selection;
  7. cin>>selection;
  8. if(selection<31 &&
  9. selection["\0\0\1\1\0\1\0\1\0\0\0\1\0\1\0\0\0\1\0\1\0\0\0\1\0\0\0\0\0\1\0"])
  10. cout<<selection<<" ist eine Primzahl unter 32.\n";
  11. }
  12.  
Success #stdin #stdout 0.01s 2728KB
stdin
5
stdout
5 ist eine Primzahl unter 32.