#include<stdio.h>
int main()
{
    int i,j[10],n,k,x;

    scanf("%d",&n);

    for(i=0;i<n;i++)
    {
        scanf("%d",&j[i]);          
    }

    for(i=0;i<n;i++)
    {
        printf("Case %d: ",i+1);

        for(k=1;k<=j[i];k++)
        {
            if(j[i]%k==0)
            {
                printf("%d ",k);

                if(k==j[i])
                {
                    printf("\b\n");
                }
            }
        }
    }  
    return 0;
}

asked 28 May, 13:09

the%20catalyst's gravatar image

the catalyst
1018

edited 29 May, 16:27

Mosharraf%20Hosain's gravatar image

Mosharraf Hosain ♦
1.0k18

Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×416
×5
×2

question asked: 28 May, 13:09

question was seen: 87 times

last updated: 29 May, 16:27