c

Is there a directory of C libraries?

Hello everyone I have now begun to apply my knowledge of C, I am actively writing a program, and I have a small ambiguity tha ... ch a thing in the C language or has it always been there, and there is chaos with libraries and documentation to her? Thanks!

Changing the places of the maximum and minimum elements in the array

You need to change them(the maximum element to the place of the minimum,and the minimum to the place of the maximum), in the ... cout<<"\nМинимальный индекс: "<<min_index<<endl; } Thank you all so much! Still learning and learning)

Which compiler or environment to use for working with the book "Programming for Windows 95" by Charles Petzold"

At the moment, I'm reading a book by Charles Petzold, "Programming for Windows 95". When compiling the codes from the book, t ... p\cc8J0wBY.o:hellowin.c:(.text+0x1c4): undefined reference to `PlaySoundA@12' collect2.exe: error: ld returned 1 exit status

Sorting words in the C alphabet

How do I sort the words of a string alphabetically? Where exactly-I left a note in the code. Preferably without using complex ... s[i].num, numbs[i].mess); puts("---------------------------------------------"); } } return 0; }

A string type in the C language. How do I create a string correctly?

I read that there is no string type in the C language, and all strings are arrays of characters. That is, we need to determin ... (%i)\n", s, strlen(s), sizeof(s)); s = "abc"; printf("3: %s :%i (%i)\n", s, strlen(s), sizeof(s)); return 0; }

How pointers work in C

I'm trying to figure out the pointers. It seems like I started to understand them, but after these two simple functions and t ... 1, &c2); swap(&c1, &c2); printf("c1 = %d, c2 = %d\n", c1, c2); return 0; } Result: с1 = 2, с2 = 1

The number of bytes that a UTF8 character occupies in a char * string?

To iterate through the words of a UTF8-encoded string, I needed to figure out how to find out the total number of bytes of a ... ul. On SO, they write that it is taken from the source code glib's gutf8.c. So I wonder what principle underlies it. Thanks.

How do I replace a character in a string in C?

When learning the C language, the question arose, why can't I change the first letter of the name strings? #include <stdio ... kes integer from pointer without a cast [-Wint-conversion]. Running the program outputs instead of the expected "RWE", "DWE".

Single-line implementation of strlen() in C

Recently I attended an interview, one of the tasks was to implement the functionality of strlen() without using third-party f ... S: also started a topic on SO on the same topic. I hope it will be interesting for those who participated in the discussion.

How do I determine if a UTF8 character is alphanumeric?

Suppose I have a string" hello " in UTF8 encoding. This string is in the C-string char *str. I want to know how I can determ ... k the entire range of the Russian alphabet. I suspect that there is some evidence hidden here, which I do not yet understand.

Why does the CreateThread function start the function immediately after creation?

There is a problem with parallelizing the output to the console screen: History: execution of WriteConsoleOutputW takes long ... hreads, which is time-consuming. Are there any options for how to make a call launch? Addition: Here's what I'm rendering

int main (int argc, char *argv[]) does not accept Russian characters as an argument

Maybe there is an answer somewhere, but I didn't have time to find it, or maybe I didn't look enough... Why int main (int ar ... I'm not in a hurry, I want to delve into everything! Help, tell me who knows why this is so and how to solve it is possible?

C / C++ - creating a GUI

Recently, I wanted to start my own project, I have an idea-but the question arose with the implementation, in particular with ... my question: what you need to know and what you need to learn to start writing a GUI in C++ with pom. Visual Studio? Thanks!

Sorting by simple selection method

#include <stdio.h> #include <stdlib.h> #include <math.h> int main() { int a[10], b; for (i = 0; i ... } } for (i = 0; i < 10; i++) { printf("%i", a[i]); } system("PAUSE"); return 0; }

How does the C stack work when calling a function with a return value?

What happens to the stack when the func () function is called if the following code is executed? char* func(char* p) { char buf[MAX_LEN]; sprintf(buf, "data: %s\n", p); return buf; } Question from the C/C++interview

Declaring links in C

From the C tutorials, I often see the following link declaration: int num = 1; int &ref = num; However, this option d ... can't figure out what the problem is. It would be very nice to see a proper C link declaration or a solution to the problem.

Function without prologue and epilogue

How can I set a function without a prologue and an epilogue so that only the body code is created? For example, to have the ... op 4: 5d pop %ebp 5: c3 ret Are there standard C tools (visual c, gcc) ?

Bits in C++ on the example code.

People help out there is nothing in the Internet about bits on C++, or else they are called bit fields. The code is there, bu ... ugh 32 characters) but for what. Well, in general, this fragment is generally stupid. I don't understand help me understand.

An exception was raised at (msvcp140d.dll)

The program defines the number system by prefixes if 0x or 0X, then 16 СС, as well as with 2 СС. The code is the same for 16 ... ase, 2 jmp end_program de: mov base, 10 end_program: } cout << base << endl; }

Learning multithreaded programming

Looking through vacancies for the position of C / C++ programmer, I noticed that knowledge of syntax, OOP and algorithms is n ... rent technology, the basics that can really be comprehended in a week of active and persistent study. Thank you in advance!