U E D R , A S I H C RSS

One/윤현수

{{|
1 2 5 6 8 10
|}}
~cpp 
#include <stdio.h>

int main(){
int i;
for(i=1;i<=10;i++)
{
    if (i==3 || i==4 || i==7 || i==9)
    continue;
    printf("%d ",i);
}
    system("pause");  
}

1 - 10 합
~cpp 
#include <stdio.h>

int main(){
int i;
int plus=0;
for(i=0;i<=10; i++)

{
    plus+=i;     
}
printf("%d",plus);


    system("pause");  
}

. 1 64, 2 10, 3 23, "error"
~cpp 
#include <stdio.h>

int main(){


int i;

printf(" "); scanf("%d" ,&i);
if (i==1)
printf ("64");
if (i==2)
printf ("10");
if (i==3)
printf ("23");
if (i>3)
printf ("error");




    system("pause");  
}


~cpp 
#include <stdio.h>

int main(){
   

int a [10];

int c;



for (c=0; c<=9; c++)
{      
   a[c] = 10-c;
printf("%d ",a[c]);
               
}



system("pause");  


}

Valid XHTML 1.0! Valid CSS! powered by MoniWiki
last modified 2021-02-07 05:23:54
Processing time 0.0112 sec