c tag

1304 questions


2 answers
145 views
0
C fopen vs open

I learned both in Linux class, but open is only on the test and I've never actually used it.You can open both files, but even if you look at other codes, they only use fopen files. Why is that?

2 years ago

1 answers
73 views
0
What does "void *p = &&abc;" do?

void *p = &&abc;I saw a code like this, but I don't know what it's doing. I've seen a lot of double pointers, but doesn't & mean the address?And you need two operands, so this isn't it.Wha...

2 years ago

1 answers
72 views
0
Binary format specifier in printf

All I know is decimal, octal, hexadecimal outputIs there a binary formatter?I'm using gcc. I hope I can use it like the code belowprintf(%d %x %o\n, 10, 10, 10); //10 A 12\nprint(%b\n, 10); //%b\n

2 years ago

1 answers
100 views
0
Why is it "a"! = "a"?

void main() { if(a == a) printf(Yes, equal); else printf(No, not equal);}Output: No, not equal I thought it would be true because the two of them are the same string, but why did the false appear?

2 years ago

1 answers
88 views
0
Is there an easy way to initialize the entire C/C++ array to -1?

int array[100] = {0};I heard that the entire silver element is set to zero, so I thought I just need to set oneint array[100] = {-1};So the first element is minus 1, and the rest is zero.I don't want ...


1 answers
32 views
0
Requires a C/C++ code to screen capture in a Windows environment

We are producing a screen casting program for Windows to film game videos.Speed is important. I'm looking for a way other than GDI, but I can't find the relevant information well.Which way should I lo...

2 years ago

1 answers
98 views
0
What does void mean in C-affiliated languages?

What does void mean in C-affiliated languages?Void is used a lot like this, but I wonder what void means.

2 years ago

1 answers
82 views
0
Type specifier %i, %d difference

I know that you can use both the format specifiers %i and %d when printing integers. What's the difference between you two? Did you make it separately?

2 years ago

1 answers
32 views
0
I think there's a problem with the code executor.

I wrote it in c language in the code executor and executed it, but strangely enough, the print is all working, but I can't input it and calculate it by myself;

c
2 years ago

1 answers
99 views
0
Can I write or in #ifdef?

It's a very basic question, so I'm a little shyI'm going to do the same thing on Linux and Android, so I'm going to tie them up. I thought I could do | of course, but I couldn't...How should I write o...

2 years ago
« - 63 - »

© 2024 OneMinuteCode. All rights reserved.