Top "C" questions

C is a general-purpose programming language used for system programming (OS and embedded), libraries, games and cross-platform.

How can I get double quotes into a string literal?

I have the following output created using a printf() statement: printf("She said time flies like an arrow, but fruit …

c++ c string escaping string-literals
Convert objective-c typedef to its string equivalent

Assuming that I have a typedef declared in my .h file as such: typedef enum { JSON, XML, Atom, RSS } FormatType; …

c objective-c enums typedef
What do pty and tty mean?

I noticed there are many mentions of pty and tty in some opensource projects, could someone can tell me what …

c unix networking tty vocabulary
What's the difference between size_t and int in C++?

In several C++ examples I see a use of the type size_t where I would have used a simple …

c++ c types int
What causes the error "undefined reference to (some function)"?

I get the error: main.o(.text+0x1ed): In function `main': : undefined reference to `avergecolumns' collect2: ld returned 1 exit …

c linker-errors
I do not understand how execlp() works in Linux

I have spent the last 2 days trying to understand the execlp() system call, but yet here I am. Let me …

c linux exec
C: convert double to float, preserving decimal point precision

i wanted to convert double to float in C, but wanted to preserve the decimal point exactly as possible without …

c floating-point double c89
Why do we need C Unions?

When should unions be used? Why do we need them?

c unions
How do you determine the size of a file in C?

How can I figure out the size of a file, in bytes? #include <stdio.h> unsigned int fsize(…

c file io filesize
What is the difference between a static and const variable?

Can someone explain the difference between a static and const variable?

c++ c static constants