Danya🔥
J
Ludovic 'Archivist'
Any thoughts on gitea?
It is simple and works well (even though I have to update my instance, the 2 years uptime is a bit too much)
J
Thanks
Ludovic 'Archivist'
Linus doesn't mind OOP, what he doesn't like is hidden abstraction
Azhar
How can i change double to string my vertual function
三体183号
Finally found a group with a good environment
Angelo
Hello guys someone can help me with a simple c code?
Jojo
A simple like hello world
#include <studio.h>
Int main{
Pprintf("hello world");
}
Angelo
Basically i have two functions, the first one is a function that depends on two variables (z,y) and it's a straight function+ a parabola and when I increase the y the angle of the straight line descrease and the second function is only one variable with y.
Basically i want to write that along the y axis i have the vector field of the function of one variable and along the z axis i have the vector field of the function of 2 variable.
Dag † Weg
Jojo
Peace
Why there is a type conversion error ?? And how to solve it ??
Error says : no viable conversion from '__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char>>, std::__cxx11::basic_string<char>>::value_type' (aka 'std::__cxx11::basic_string<char>') to 'int'
vector<int> v1{1,2,3,4};
int v1_size=sizeof(v1)/sizeof(v1[0]);
string str="";
for(int i=0;i<v1_size;++i){
str+=static_cast<string>(v1.at(i));
}
Robert
you can't Transfer int to string here
Robert
If you want to print these int as string or something like that,you can use to_string function
Robert
str+= to_string(v1.at( i ))
Anonymous
Alviro Iskandar
yeah, should be
int v1_size = v1.size();
Alviro Iskandar
or size_t v1_size = v1.size(); to be precise
Robert
Robert
So this error is not because static_cast rather than v1_size here?
Anonymous
Interested contact me.
Anonymous
Hello
MᏫᎻᎯᎷᎷᎬᎠ
Anonymous
I'am beginner, please can you send me execises.
Anonymous
C
Anonymous
Programming
MᏫᎻᎯᎷᎷᎬᎠ
Anonymous
Anonymous
👍
Anonymous
Hey does anyone prefer c++98 to this modern junk
Madhav
Why is my code showing std::outofrange and not running my functions? I tried searching on google but because I m a complete beginner so i couldn't understand it
Madhav
This is my code
Danya🔥
Madhav
Danya🔥
Yes..?
The problem is here
Danya🔥
Think about it
Madhav
Umm.. Ok sir.. I will try
Madhav
But the online tutor had the same code... His code ran mine didn't
Alviro Iskandar
Danya🔥
If you'd use a range based for loop or standard C++ algorithms, there wouldn't be any problem
Alviro Iskandar
sometimes it happens to work by luck
Danya🔥
He used at member function
Madhav
MᏫᎻᎯᎷᎷᎬᎠ
Anonymous
Templates are turning complete. You can write a parser using them
MᏫᎻᎯᎷᎷᎬᎠ
Dima
the c++23 standard should be as a different language lol imo
MᏫᎻᎯᎷᎷᎬᎠ
Dima
c++++ maybe
MᏫᎻᎯᎷᎷᎬᎠ
As always
They shouldn't name it C++ anymore
MᏫᎻᎯᎷᎷᎬᎠ
Maybe it's right, we should divide the language into seperated standards
Dima
hard times create strong programmers
strong programmers create weak languages which are being used by weak programmers
weak programmers create hard times
Anonymous
Which app can i used for coding c
Dima
its cyclic so idc
J
MᏫᎻᎯᎷᎷᎬᎠ
Anonymous
MᏫᎻᎯᎷᎷᎬᎠ
Yeah, but life is short lol
The language is being abandoned
Rust is taking over
I've seen a lot of programmers turned to Rust
Anonymous
MᏫᎻᎯᎷᎷᎬᎠ
I really wish if we have that edition-like feature in C++
It would be cool
J
Which type
Any C/C++ ide. In windows, VS Studio. If you are comfortable with text editors, then VSCode
Anonymous
MᏫᎻᎯᎷᎷᎬᎠ
I'm not a Rust Dev, I really would love for C++ to get over from its dirty hole, but the committee just don't get it
MᏫᎻᎯᎷᎷᎬᎠ
MᏫᎻᎯᎷᎷᎬᎠ