mito
Go sleep
Is there a c++ bot for tg
رغد🖤
Go sleep
That i can program in telegram
Danya🔥
You do not make any sense
I'd suggest to address your questions to ChatGPT from now
Maybe the machine will be able to understand you
Go sleep
Bruh
Go sleep
U not very nice
Pavel
That i can program in telegram
The telegram API and UI would make programming through a bot a terrible experience. It is better to download some C++ compiler app (there are multiple for Android and I expect should be for iOS)
Pavel
Telegram is just not designed for that
Sid Sun
well.. there is this
Chat Boss
Aze sent a code, it has been re-uploaded as a file
Aze
Anonymous
Hi, guys how many times the function getline(); can it be called within a loop structure to read a string? I'm trying to read a struct with two members a string name and an array age both with length 2. When I execute the reading inside the for getline(cin,p.name[i]); it is once name and age but the second time it no longer reads the name just the age is how it skips up on the second iteration.
Elfa Metesar
Elfa Metesar
cin.clear();
cin.ignore(10000,'\n');
Anonymous
I am seeking for the site that provides free courses along with the certificates..
Anonymous
do you guys know some.?
Danya🔥
Certificates mean nothing
𝘞𝘦𝘢𝘳𝘪𝘯𝘨𝘔𝘦𝘥𝘢𝘭
hey, is there a way to hide the output from execlp? I'm trying to pipe the output of a command to another and then read the result, but I only get the result on the terminal. I don't want this behaviour, I want that the second command runs and I get the output in a string, is it possibile?
code: https://pastebin.com/5Mzr8eYa
Anonymous
Given that each sub-array has exactly 3 elements, element access can be done like this:
for (int i = 0; i < 9; ++i)
printf("%3d\n", arraysArray[i / 3][i % 3]);
Also note that there are only 9 elements, so the end value of i should be 9.
Elfa Metesar
𝘞𝘦𝘢𝘳𝘪𝘯𝘨𝘔𝘦𝘥𝘢𝘭
Elfa Metesar
I can't do this with popen: man man | col -b
int main()
{
FILE* cmd = popen("echo oki | grep -o 'i'", "r");
char output[256];
while(fgets(output, sizeof(output), cmd)) {
cout << output << endl;
}
return 0;
}
Elfa Metesar
this redirection in popen works for me
Elfa Metesar
i can't send ss
Elfa Metesar
𝘞𝘦𝘢𝘳𝘪𝘯𝘨𝘔𝘦𝘥𝘢𝘭
𝘞𝘦𝘢𝘳𝘪𝘯𝘨𝘔𝘦𝘥𝘢𝘭
I should have fixed
Mustafa
I want to develop a tetris game in c, which libraries do i need for making that?
Ncurses? Sdl? Allergo? I don't know which one has the best functionality and mobility for graphic games?
Mustafa
I need someone to answer this😐
Gawr
Raylib is also a good choice. It provides cheatsheet for all apis and in my opinion it is easier to use than SDL.
Mustafa
Melvin ♣️
does anyone have c++ book in english
Mustafa
Ali
Plz Resolve my issue:
https://github.com/leostratus/netinet/issues/1
ゾロ
guys, I am new to makefile and I come across a makefile that with many "makefile variables ", I want to replace those variables with the actual value, how to do that
Sourish
Anyone Know How To Handle Wamp Server..??
Hritik
I have a question
Suppose we have a multiset of string
Now I'm iterating over the set as
for(string s: set){
Now if i delete all the elements within the set so in the next pass it is throwing an error
}
How can I fix it
Elfa Metesar
Elfa Metesar
for (auto it = a.rbegin(); it != a.rend(); ++it) {
a.erase(*it);
}
I used reverse iterators here because for some reason set returns a contant iterator if it's not reverse, it does the same thing anyway
Elfa Metesar
oh, you used multiset, well the same logic with it
Elfa Metesar
Chat Boss
Hritik Kaushik sent a code, it has been re-uploaded as a file
Hritik
im getting this error
AddressSanitizer: heap-use-after-free on address
@elfametesar
Elfa Metesar
hold on
Elfa Metesar
i mean i guess it shouldn't be safe since you're iterating through indexes and once you delete an index or insert an item, you break the hierarchy
Elfa Metesar
maybe it would be safe to delete/insert using simpler types of containers, but since this is somewhat ordered, it poses a risk is what i think. idk tho, im not really an expert
Hritik
actually i was trying to do something like a dfs here
Hritik
so i dont pickup same element in the same path again i was removing it from the set
Hritik
Elfa Metesar
Hritik
because the strings should be sorted if multiple path exists
Elfa Metesar
i figured you needed sorting lol
Elfa Metesar
that's the kinda thing that kinda ruins the for loop deletion thing for you ig
Elfa Metesar
Hritik
instead of deleting i will try to keep track of visited string maybe that will work
Elfa Metesar
yeah
Chat Boss
Dima
lol
Elfa Metesar
Anonymous
lol
Yeah. I was pissed off too. Maybe an exception can be made for admins 😉
Anonymous
Shaonianan
hi guys,I want to custom deleter, but is error when i want two para:
Shaonianan
class Test
{
public:
Test()
{
cout << "Test()" << endl;
}
~Test()
{
cout << "~Test()" << endl;
}
};
class Deleter_
{
public:
void del(Deleter_ &d, Test *p)
{
std::cout << "Deleting ..." << std::endl;
delete p;
}
};
int main()
{
std::shared_ptr<Test> spTest;
spTest.reset(new Test(),
std::bind(&Deleter_::del,
&d,
_1));}
Shaonianan
somebody help me? thank you guys..