M.Khorram
Nobody is going to copy and rewrite your code from a screenshot
in many cases there is no need to copy the code they are just asking for your view point
M.Khorram
lets go #ot
Anonymous
in many cases there is no need to copy the code they are just asking for your view point
There always is. If you are too lazy to do your own work why do you expect others to not be lazy then?
Talula
in many cases there is no need to copy the code they are just asking for your view point
It doesn't work like that, I can't give my view just looking at code... I need to test it before I could give my view...
Talula
And I've been programming for last 23 years.
Anonymous
If you are posting code here you need help
Anonymous
We are not obligated to help you fix your mess
Anonymous
So do the bare minimum so that people who just see this chat for a few minutes a day can quickly help you
M.Khorram
We are not obligated to help you fix your mess
you are not "obligated to help" in any way But it limits the way people can talk about their coding issues
M.Khorram
And I've been programming for last 23 years.
There are simple cases that you might not need to test. The last one was one of them
Anonymous
Pasting is the only way you will get help here anyway. Screenshots will be ignored anyway So by posting a screenshot you are spamming
Anonymous
Anonymous
Screenshot of code and the classic "I am getting an error" He didn't even describe the error
Talula
There are simple cases that you might not need to test. The last one was one of them
Still there is no harm is using paste bin... Secondly who decides what is "simple" and what is "complex"?
Talula
What might be simple for me might be very complex for someone who just started programming.
M.Khorram
Dear Rashu Ahmed, You can ask me your questions from me via direct message I hope I could help you
Anonymous
Who can help me configure asterisk server?
The
God.
😐
Roxifλsz 🇱🇹
Roxifλsz 🇱🇹
Bross
...
M.Khorram
Who can help me configure asterisk server?
Hi, You may find someone to help you in other groups, but not here
Talula
Hi, You may find someone to help you in other groups, but not here
It is a C/C++ group, it is like entering a church and asking them about Hindu gods...
klimi
i am interested tho
Vlad
i am interested tho
"I know, father, but I'm interested tho"
M.Khorram
It is a C/C++ group, it is like entering a church and asking them about Hindu gods...
"entering a church and asking them about Hindu gods", but you can avoid sarcastic answers like "God"
Asdew
It is a C/C++ group, it is like entering a church and asking them about Hindu gods...
What's wrong with that? Pastors are very nice (my mother actually is one) and they can help you with that.
MᏫᎻᎯᎷᎷᎬᎠ
Quran*
Anonymous
Hii
3zoz
i try all thing but i fill 😥
Talula
i try all thing but i fill 😥
You can write the formula in http://rogercortesi.com/eqn/index.php
Talula
Don't post camera shots...
3zoz
sorry i don't know i just want some help
3zoz
sorry 💙
3zoz
r=√(f1)²+(f2)²+2f1×f2×cos
3zoz
this mark √ root
Anonymous
/warn screen photo is the error
V01D
i think it is lack of white space
Nah, C++ doesn't care about indentation. This ain't python (LUCKILY!) 😉
Talula
i don't know how
Try this https://www.codecogs.com/latex/eqneditor.php
Alex
you can`t change it
Alex
regarding constant memory its implementation defined I suppose
Harsh
String literals are constant in a way
Harsh
const int a=5; This is a constant 5 This is a literal
Alex
can be placed in read only memory, can be not
Harsh
So if u do char a[]="hello world"; "hello world" is a string literal that can't be changed. Ofcourse u can change a[], but that doesn't change "hello world"
Harsh
U can't do "hello world"="hello c++" Cuz it's string literal
V01D
With const char a[] = "hello world"; you cannot do char[1] = "a";
V01D
const char should be used in pointer strings aka C style strings
Harsh
Better learn about tokens in c++ They'll explain constants and literals
Harsh
Constant is still a variable
Harsh
Literal is not
Harsh
const int a=5; This is a constant 5 This is a literal
Here a constant variable holds value 5 But value 5 itself is a literal
V01D
You can modify the index of a string literal, but you cannot do that with a const string
V01D
a[1] = 'a';
V01D
You cannot do a = "new string"; though
V01D
You can change a LITERAL at given index. A constant CANNOT be changed
V01D
//Literal char a[] = "string1"; a[0] = 'S'; //OK a = "new string"; //ERROR //Const const char a[] = "string2"; a[0] = 'S'; //ERROR. a = "new string"; //ERROR
V01D
Those are called string literals, not string constants
Harsh
5 is literal Can u change it?
Harsh
Literals are raw values
Harsh
And they are treated as const when passed as function arguments
V01D
5 is literal Can u change it?
I am talking about strings specifically
Harsh
I am talking about strings specifically
Yea u can't change string literals either. cout << "Hello World"; You can't change the literal hello world However if u assign a literal to a variable as value Then u can change the value of variable
Harsh
https://stackoverflow.com/questions/44767354/confusion-between-constants-and-literals#:~:text=A%20literal%20is%20a%20value,various%20times%20during%20the%20program.
Harsh
But you can change a character at a given index
Try changing "Hello world"[2]='b';
Harsh
U can't
Harsh
Yes
V01D
Try changing "Hello world"[2]='b';
char a[] = "bla"; a[1] = 'a'; Works though
Harsh
char a[] = "bla"; a[1] = 'a'; Works though
"bla" is a literal, char a[] is not
V01D
"bla" is a literal, char a[] is not
Correct. I mean you can change string literals inside of a variable
Harsh
In other words, hardcoded values are literals