malloc is used to reserve some portion of memory
This memory will be referenced as a pointer
As already said, this is useful when you don't know explicitely how much memory you would need when...
Type: Posts; User: sisovich
malloc is used to reserve some portion of memory
This memory will be referenced as a pointer
As already said, this is useful when you don't know explicitely how much memory you would need when...
A brute force approach would be
Starting N
Convert N to a string using sprintf (Nstr)
Check if Nstr is a "palindrome string"
Increase N and go back to the first until your final condition
...
As far as I know there is no a "unique" solution. GCC and GLIBC provides many "hidden" utilities to manage trees, hashes, queues, a long list
The STANDARD C itself does not solve your questions as...
void removeCharSign (unsigned char ubuffer[], char buffer[])
{
int i;
for( i = 0; i < (int)(sizeof ubuffer / sizeof *ubuffer); ++i)
{
buffer[i] = ubuffer[i];
}
buffer[i] = '\0';
}
If you get "Too many open files" and you have a function that open a file....
could be posible you call this function from a recursive function elsewhere ?
are you sure you don't get out from the...
If your order algorithm is working, well then is ok
However, for future references remember there is an standard function in the stdlib named qsort
you have to create a function to compare the...
I tried to read the code, but I must admit I don't understand well how it works
For instance, you use some variables defined elsewhere and not in the same function, numbers, solution, N, etc(I guess...
Well, I didn't compile this, I only want to describe another way, using for and initializing color depending on the number of row.
This will contain for sure some errors, but the idea I think is ok....
what it's important is to know that you cannot trust in any determined size , that's why fgets is a nice function because you call it saying you want to read at most N chars, so in this way you avoid...
I don't use C for web suff (beware with the overflow buffers, check always all input strings) , however, knowing is liunx, you must have available tons of C libraries for CGI.
Google CGI C...
Well as Bubba said, when you deal with I/O issues signals are almost mandatory, if you are in a Linux environment , try man signal and you will see the start
If you want to apply a kind of brute...