hi,
int array[][10]={{2,4,6,8,10,12},{1,2,3,4,5,6,7,8}};
int size=sizeof(array)/sizeof(array[0])
I am getting incorrect result with it...
hi,
is there a built in function to get size of array ? thanks
Hi!
I will try to explain my problem as well as I can... i hope you can help me...
i tried so hard but i wasn't able to solve it...
i always have this file:
15 nick
25 marcus
18 ...
Assume unsigned short is 1 byte and unsigned int is 2 bytes. Please consider following code Snippet:
void program(unsigned short *dst, unsigned short const *src, size_t num)
{
unsigned ...
hi,
if i use getc to read from file , can i assume it to be slower than fgets or fread or it does not matter? thanks a million..
I'm a delphi coder but I do some small C programming under linux using the gcc compiler. I have absolutely no knowledge of c++, but I manage ok with C (using the man and some books when I'm in...
hi, porting a project from vs2003 to vs2005
brings some problems.
main errors occur using mem_fun with 2 arguments. (compiler says he wants 1)
sigc::mem_fun( this, onEnterPressed)
sayi...
hi,
i wanted to confirm whether with dynamic memory allocation, we can allocate how much memory we want to ?
for example 1 milllion...
if i do, int [1 million]..that would definitely ...
Hi, i have am trying to intercept calls to malloc and calloc and display but im having some problems. Things starts to go wrong when calloc is called..
calloc x x x
malloc x x
print re...
In this problem, let REF(x.i) --> DEF(x.k) denote that the linker will associate an arbitrary reference to symbol x in module i to the definition of x in module k. For each example below, use...
I'm having an issue with my conversion from binary to hexadecimal. The code I wrote is reading the binary number from left to right instead of right to left. If the binary number, is divisible...
I need this question answered to HELP do my homework. I AM NOT asking anyone to do it for me. Say I have the following code: (this is just a function definition at the bottom)(AND the string f...
This is an embedded application running under Linux. I need to add the ability to my makefile to build a variable that will be a list of all the include directories in the path up to and inclu...
Hi,
I have a C function, attached, which is usually called from a ProCobol program. I need to call this from SQL, passing in information taken from the database.
Is there a way of doing th...
Does the last entry in enumeration type definition must have comma after it? For example,
typedef enum {
BLUE = 0,
RED,
GREEN
} color;
Do I need comma after GREEN?
T...
Hello,
I was wondering if someone could help me figure out one possible output to the control flow program below, thanks alot!
#include "csapp.h"
int main()
{
int x = 3;
if (F...
hi,
i have a function that allocates memory for int.
my problem is that i want to use the same function to allocate memory for char...
is there such thing as global function
void a...
hello. jus to confirm. after reading up on realloc, i get the concept that realloc does the following:
Please let me noe if im wrong :) thx
I have an old macro that I wish to delete. I want all the other programmer not to use it any more. So I want to insert a warning that will be displayed at compile time, when this macro is used...
I have this old fixed idea, probably acquired in the dawn ages of K&R, that something like
char *str = "123";
*str = '0';
is OK and will set *str to "023".
Clearly I am wrong, bu...
Hi,
I compile the webserver sample in gSOAP project with cross-compiler mipsel-uclibc-gcc. The mipsel-uclibc-gcc compiler shows me the error message:
----------------------------------------...
I need the following c code to be translated to vb.net. The code is from: http://www.netfor2.com/fcs.htm
For check,the function should return E443 (hex) when A0080223C993 (hex) is calculated...
Hi,
I need to draw a simple line in pixel, but using standars headers (conio.h stdlib.h stdio.h etc) I cant use graphics.h coz is Borland.
I dont need something like:
for(int i=0;i<60...
hi, can i use exec to run another program i created?
Hi
I'm currently writing a wheel of fortune project. I though I finished with it the text file containing the clues was provided, now however my code isn't working. My problem is that when ...