Search:

Type: Posts; User: Alexie

Search: Search took 0.01 seconds.

  1. Replies
    27
    Views
    2,941

    OK thanks . i manage to solve the problem already...

    OK thanks . i manage to solve the problem already :)
  2. Replies
    27
    Views
    2,941

    i have do a research on inword = 1; else inword =...

    i have do a research on inword = 1; else inword = 0; that all the number and char = 1 and space = 0; how can i do it on my code?
  3. Replies
    27
    Views
    2,941

    After looking at the code again. I think i got a...

    After looking at the code again. I think i got a problem with it again.


    #include<stdio.h>
    #include<stdlib.h>
    #include<string.h>
    #include <ctype.h>

    int main()
    {
  4. Replies
    27
    Views
    2,941

    Thanks for that too. good idea:wink:

    Thanks for that too. good idea:wink:
  5. Replies
    27
    Views
    2,941

    Hey Adak! Thanks for your explanation. I got my...

    Hey Adak! Thanks for your explanation. I got my code working.


    if((str[i]== ' ' && str[i+1] != ' ' && inWord++ ))
    and also
    printf("\n\nThe total number of words are %d ",...
  6. Replies
    27
    Views
    2,941

    i did use for counting space ...

    i did use <ctype.h> for counting space


    while(str[len]!='\0') len++;
    for(i=0;i<=len;i++)
    {
    while( isspace( str[i] )) { space++; i++; }
    {continue;}
    ...
  7. Replies
    27
    Views
    2,941

    Oh. so how should i code to let the program know...

    Oh. so how should i code to let the program know it begin with a space?
  8. Replies
    27
    Views
    2,941

    I manage to solve the first error by change the...

    I manage to solve the first error by change the line to:
    if((str[i]== ' ' && str[i+1] != ' '))

    Input: a[space][space][space]d
    Output: 2 words

    But the next problem I can't solve is:

    Input:...
  9. Replies
    27
    Views
    2,941

    Ok thanks alot. I will try to get a copy soon :)

    Ok thanks alot. I will try to get a copy soon :)
  10. Replies
    27
    Views
    2,941

    I don't have any book to learn. I was learn it...

    I don't have any book to learn. I was learn it through youtube.
  11. Replies
    27
    Views
    2,941

    Thanks for the reply. Can you guy help out with...

    Thanks for the reply.
    Can you guy help out with my code? I'm still learning in my progress.
  12. Replies
    27
    Views
    2,941

    Count word in a string.

    This is a simple program but i got a small problem with it.


    #include<stdio.h>
    #include<stdlib.h>
    #include<string.h>

    int main()
    {
    char str[50];
Results 1 to 12 of 12