rsmo

by weqadqa on March 12th, 2010

nije gotovo teba samo da ispise sva slova u tekstu sto ne uradi

Syntax: C
Show lines - Hide lines - Show in textbox - Download
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
int main()
{
    int i,k,n=0;
    char A[100];
    printf("\n-Uneti tekst : ");
    gets (A);
    for(i=0;A[i]=='\0';i++)
        if(A[i]==isalpha(A[i]))
            k++;
    int B[k];
    char C[k];
    char a;
    k=0;
    i=0;
    for(i=0;A[i]=='\0';i++)
        {
            a=A[i];
            for(k=0;A[k]=='\0';k++)
                {
                    if(a==A[k])
                        n++;
                }
            C[i]=a;
            B[i]=n;
        }
    puts(C);
 
 
 
    return 0;
}
 

Leave a Reply

Note: XHTML is allowed. Your email address will never be published.

Subscribe to this comment feed via RSS