Guest User

Untitled

a guest
Jan 21st, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.40 KB | None | 0 0
  1. using System;
  2. class primi
  3. {
  4. static void Main()
  5. {
  6. int a = 2, l = 1, g = 0;
  7. decimal div = 0;
  8. string divisione;
  9. for (int h = 0; h < 1; )
  10. {
  11. l = 1;
  12. while (l <= a)
  13. {
  14. div = a / l;
  15. l++;
  16. divisione = Convert.ToString(div);
  17. for (int x = 0; x < divisione.Length; x++)
  18. {
  19. if (divisione[x] == ',')
  20. {
  21. goto continua;
  22. }
  23. }
  24. g++;
  25. continua: ;
  26. }
  27. if (g == 2)
  28. {
  29. Console.WriteLine(a);
  30. }
  31. a++;
  32. g = 0;
  33. }
  34. }
  35. }
Add Comment
Please, Sign In to add comment