1F Angus Yang 大二上 (2013/08/22) 1 #include<stdio.h>
cx = 0 ; cb = cb + 1 ; if(cnt==cb) } |
2F Wen-Sen Chen 國一下 (2013/12/18) 1 int isPerfect(int x) { int sum=0,i; if(i=1;i<x;i++) //判斷1~(x-1) { if(x%i==0) //判斷i是否為x的因數 { sum=sum+i; } } if(sum==x) return(1) ; //如果和等於x 傳回1,否則傳回0 else return(0); } |