diff --git a/cmbn - Copy.c b/cmbn - Copy.c new file mode 100644 index 0000000..47903d9 --- /dev/null +++ b/cmbn - Copy.c @@ -0,0 +1,37 @@ +#include +void main() +{ + int i,ct,n,k,x; + for(n=1;n<=3;n++) + { + ct=1; + for(i=0;ct<=3;i=(i+1)%3,ct++) + { + k=i+1; + if(n==3&&ct==3) + { + k=1; + } + if(k==n&&ct<3) + { + //printf("hdhbc") + continue; + } + + if(k!=n&&ct<3) + { + x=k; + continue; + } + if(ct==3) + { + printf("%d",n); + printf("%d",x); + printf("%d\n",k); + printf("%d",n); + printf("%d",k); + printf("%d\n",x); + } + } +} +} diff --git a/demn - Copy.c b/demn - Copy.c new file mode 100644 index 0000000..7007f49 --- /dev/null +++ b/demn - Copy.c @@ -0,0 +1,47 @@ +#include +void main() +{ + int i=1,a[6],n; + printf("enter sum\n"); + scanf("%d",&n); + switch(i) +{ + case 1:{ + a[1]= n/100; + n=n%100; + } + + case 2:{ + a[2]= n/50; + n=n%50; + } + + case 3:{ + a[3]= n/10; + n=n%10; + } + + case 4:{ + a[4]= n/5; + n=n%5; + } + + case 5:{ + a[5]= n/2; + n=n%2; + } + + case 6:{ + a[6]= n/1; + + } +} + + printf("hundreds=%d\n",a[1]); + printf("fifties=%d\n",a[2]); + printf("tens=%d\n",a[3]); + printf("fives=%d\n",a[4]); + printf("twos=%d\n",a[5]); + printf("ones=%d\n",a[6]); +} + diff --git a/fm1 - Copy.c b/fm1 - Copy.c new file mode 100644 index 0000000..77595dd --- /dev/null +++ b/fm1 - Copy.c @@ -0,0 +1,24 @@ +#include +int main() +{ + int i,ct,n=1,j; + for(i=1;i<=4;i++) + { + ct=0; + for(j=i;j<=3;j++) + { + printf("\t"); + } + while(ct!=i) + { + ct++; + + printf("\t\t%d",n); + n++; + } + printf("\n"); + printf("\n"); + } + return 0; +} + diff --git a/main - Copy.c b/main - Copy.c new file mode 100644 index 0000000..ebaca5f --- /dev/null +++ b/main - Copy.c @@ -0,0 +1,7 @@ +#include + +int main() +{ + printf("Hello world!\n"); + return 0; +}