mhdew

URI 2540

Jan 3rd, 2018
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. #include<stdio.h>
  2.  
  3. int main()
  4. {
  5. int i, n, a, count;
  6. double check;
  7.  
  8. while(scanf("%d", &n)!=EOF){
  9. count=0;
  10. for(i=1;i<=n;i++){
  11. scanf("%d", &a);
  12.  
  13. if(a==1)
  14. count++;
  15. }
  16. check=(2*n)/3.0;
  17. count=count*1.0;
  18.  
  19. if(count>=check)
  20. printf("impeachment\n");
  21. else
  22. printf("acusacao arquivada\n");
  23. }
  24. return 0;
  25. }
Advertisement
Add Comment
Please, Sign In to add comment