VatooVatoo 21 Light Poster

You can use something like this:

while ((c = getc(fp)) != EOF)
        if(c == 32) ....
rproffitt commented: I've seen such before but most of the time I want a single space to remain. +16
VatooVatoo 21 Light Poster

Maybe you could use somthing like this:

#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#define RESULT_FAILURE -1
#define RESULT_SUCCESS 0

int16_t  fun(char *iaddr)
{  
    char* p = NULL;
    int i = 0;
    int len = 0;
    int rc = RESULT_SUCCESS;

    if(strlen(iaddr)>0)
    {
        len = strlen(iaddr)+1;
        p = (char*)malloc(len );
        strcpy(p,iaddr);

        for(i=0;i<len;i++)
        {
            printf("%c", p[i]);
        }

        free(p);
    }
    else
    {
        rc = RESULT_FAILURE;
    }

    return rc;
}

int main()
{
    int rc;
    rc= fun("10.3.28");
    printf("irc=%d",rc);
    return 1;
}
VatooVatoo 21 Light Poster

Just call the method that defined for button event into timer event method.

        private void timer1_Tick(object sender, EventArgs e)
        {
            button1_Click( sender, e);
        }

you also could put null for parameters.

        private void timer1_Tick(object sender, EventArgs e)
        {
            button1_Click( null, null);
        }
VatooVatoo 21 Light Poster

As I understand this is not a recursive problem because

F(1) is not defined. Also I cant find any
F(a) = F(a+n) is not possible

so this is not recursive.

jephthah commented: I am intrigued by your post, and would like to subscribe to your newsletter. +10