28 questions
As far as I know, i+=j; and i=i+j have the same meaning int i = 5; long j = 8;If I = i+j;, it can't be compiled. If I = j;, it runs well I wonder why.
How does the next code run?It's my first time seeing it in C grammar when I think it's going well in GCC ㅜㅜWhere's that thing?What's that called?#include <stdio.h>int main(){ int x = 10; while (...
In C++, there are many ways to dynamically allocate, right?Then when should I use malloc and when should I use new?malloc If you finished freeIf new is done, deleteI know I shouldn't mix the two.
If you compile the code below into the gcc -Wall /-Waddress option,warning: the address of ‘i’ will always evaluate as ‘true’ [-Waddress]It appears.I don't know why it's coming up. I don't know what i...
!I'm asking =! not =.We didn't even assign a value in the code belowWhy is false coming out?int main(){ int a; int b = 3; return if(a =!b) { //false cout << a =! b is true! << endl; } els...
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...
What is the work of a operator in Java?For example, if you do an operation such as inta=5^n;Operator does When n is 5, the value is 0When n is 4, the value is 1When n is 3, the value is 3I don't think...
What does :: do in Foo::Bar?I thought it was related to encapsulation (private, protected), but it's not that when I looked at the definition.The :: is a unary operator that allows: constants, instanc...
- 1 - | » |
© 2024 OneMinuteCode. All rights reserved.