[C]두 숫자의 배수를 출력하는 프로그램 프로그래밍

/* 
    두 숫자의 배수를 각각 출력 하는 프로그램.
    단 두 숫자의 공 배수는 한번만 출력.
*/

#include<stdio.h>
#include<stdlib.h>
int main(){
 int i;
 
 for(i=1;i<100;i++){
   if(i%7==0 || i%9==0){
      if(i%7==0 && i%9==0){
    printf("7과 9의 공배수 : %d \n",i);
       continue;
    }
      printf("%d \n",i);
   }
   }
   system("pause");
}

트랙백

이 글과 관련된 글 쓰기 (트랙백 보내기)
TrackbackURL : http://gameboy.egloos.com/tb/1524201 [도움말]

덧글

덧글 입력 영역