Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main()
- {
- int n;
- scanf("%d", &n);
- int zbir = 0;
- for(int delitel = 1; delitel <= n; delitel++) {
- if(n % delitel == 0) {
- zbir += delitel;
- }
- }
- int brojac_na_deliteli = 0;
- for(int delitel = 1; delitel <= zbir; delitel++) {
- if(zbir % delitel == 0) {
- brojac_na_deliteli++;
- }
- }
- if(brojac_na_deliteli == 2) {
- printf("PROST\n");
- }
- else {
- printf("SLOZHEN\n");
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement