András
Is it possible?
András
Before loop
Chernykh
d[i] == 0
Use --t
András
Chernykh
I assumed that u've refered to -1 element
Chernykh
Possibly
Chernykh
Oh, forget what I said above
Chernykh
And I just continue drink my beer
infi ptr
d[i] == 0
when u r using negation we have to use single sign only
Chernykh
Can u send more verbose error?
Chernykh
Or is it all?
Chernykh
Try to debug it and figure out the line of code doin' that fkng fault
infi ptr
So?
yeah thats the standard way
Chernykh
Sometimes I see questions like that I think "r u banned in debuger"?
András
yeah thats the standard way
Or I didn't understand you, or you didn't explain, why d[i] can't be 0
infi ptr
Or is it all?
this is all bro,just segmentation fault
infi ptr
Sometimes I see questions like that I think "r u banned in debuger"?
i already ran the debugger, the problem is in for loop but i am unable to sort it out
infi ptr
Or I didn't understand you, or you didn't explain, why d[i] can't be 0
d[i] can be zero but for equality comparison if(d[i]!=0) correct only. in case u r getting confused
Chernykh
Wait until i'll drink pls
Chernykh
So
Chernykh
Beer's over, I'm in
Chernykh
Then how do u want to calculate p%d[i] != 0?
Did u watch what iteration ur code crushed?
Chernykh
And maybe I'm drunk but think that cause in condition of for, try to write not n but n-1
Chernykh
My head compiler hint me that u equate i variable to array size, but index != Size
Chernykh
And u'r referring to element out of range
José Manuel
my pleasure; for the next time, putting some cout's to show variables values will do the trick
Chernykh
Blyat'
Anonymous
hi
klimi
hi
Hi
🐉
hi guys this code: istream& operator >>(istream& in, ImpiantoSciistico& I) { in>>I.size; I.max = (I.size+1)*2; I.pista = new string[I.max]; I.difficulty = new Difficulty[I.max]; for (int i=0; i<I.size; i++) { in>>I.pista[i]>>I.difficulty[i]; } return in; } //Difficulty is enum the compiler throws this error error: no match for 'operator>>' (operand types are 'std::basic_istream' and 'Difficulty') in>>I.pista[i]>>I.difficulty[i];
🐉
Does somebody spots the error?
🐉
Dima
you need to create a friend function/operator for that class
🐉
Oh
🐉
I think I got it, ty
🐉
its a class
almost got it lol Where should I overload it?
gallo
Hi, can I ask about decompile a dll file to have the source-code in cpp or it's off topic?
Dima
it’s not possible unless its cli/c++ (.net managed)
Dima
use IDA or something
gallo
use IDA or something
Sorry, what is IDA?
Dima
Sorry, what is IDA?
IDA disassembler, shows you asm code and pseudo-C code
Dima
#googleit
Chernykh
IDA disassembler, shows you asm code and pseudo-C code
It's simpler to watch asm blocks not pseudo-C, IMHO this one isn't readable
Chernykh
Sorry, what is IDA?
Use ghidra instead, it's free and user-friendly
Chernykh
And pseudo code mostly readable
Chernykh
RE4B-EN.pdf
Chernykh
Hi, can I ask about decompile a dll file to have the source-code in cpp or it's off topic?
If u interested I'm working as reverse engineer and can help u
Anonymous
How to check os when code.cpp
Anonymous
for project platforms
Chernykh
How do I check OS with a preprocessor directive? - Stack Overflow https://stackoverflow.com/questions/142508/how-do-i-check-os-with-a-preprocessor-directive
Chernykh
#ifdef directive
Chernykh
Or u want runtime?
Anonymous
thanks pro
c
hey anybody here can help with a noob problem? i would like to get a float** from a vector<float>. say there are 6 items in the vector and i want to split them into 2 buckets with each has 3, ending up with a float**
c
thanks in advance
Yogesh Nayak
Hi guys
Yogesh Nayak
Hi rose
klimi
Hi
Hubert
Hi
klimi
Hi
Hi
c
first one points to position 0 in the vector and 2th one points to position 3 in the vector
c
and then create a float** points to the above two float*
Francisco
You could do that, I guess
Francisco
I don't know why, but you definitely can
c
is that ok? the first float* will not have a end at position 2 which I want it to
Francisco
What?