Francisco
10001st prime number?
Project euler problem, I think
Francisco
I solved it some months ago
Tokin
Is anyone here topcoder red?
Tokin
Or are they just fairytales
Tokin
Jk
StrikeShott
StrikeShott
I am thinking of applying greedy approach. Does anyone know how to import vector in c++. ?
StrikeShott
Or do any of you think other approach to get the result. ?
Dima
Read the rules
Dima
no asking for assignment solutions
StrikeShott
#include<vector>
Already tried that.
Anonymous
Read the rules
He's asking about the idea
Anonymous
Already tried that.
So, it is the only way to import vector
Anonymous
If it doesn't work, you are doing something wrong
Anonymous
#include<vector> ... std::vector<int> vector; // empty vector
StrikeShott
Thanks. Let me try this.
StrikeShott
Or maybe should i just stick with array because the size is defined already in the question. ?
StrikeShott
a[6][6], b[7][6], c[10,6];
correctmaninwrongplace
I would recommend you the occam's razor
correctmaninwrongplace
And i think that maybe other approach would be better, but greedy can work
Anmol
int *arr = new int[100](); Does this initialize the array arr to 0?
Anmol
int *arr = new int[100](); Does this initialize the array arr to 0?
I searched in google for quite a bit cannot find anything concrete
Anmol
The syntax is perfectly fine
Anmol
this is cpp, use std::vector
I'm not really familiar with vectors yet so I'd rather not
I_Interface
I'm not really familiar with vectors yet so I'd rather not
but they are more effective than dynamic arrays
I_Interface
Anonymous
but they are more effective than dynamic arrays
Let him make his own mistakes so he can learn
I_Interface
Let him make his own mistakes so he can learn
even if he will use smart pointers for this ? :D
Mat
For the elements inside, you can try yourself
Anmol
For the elements inside, you can try yourself
I did and it always came out to be 0 that's why i asked
Mat
However you should use std::array and std::vector
Anmol
However you should use std::array and std::vector
I'm not very familiar with templates. I was only taught C and they are now teaching OOPS using C++
Anmol
Who talked about templates?
Are array and vectors not used as templates?
Anmol
I'm slowly learning the workings of C++
Mat
Just read about them
Anmol
Just read about them
I will as i get there
Anonymous
Is there any possibility to do cgi programming without using any library such as cgicc
Wim
Flat out CGI just sets environment variables which you can read and parse
Anonymous
Sure, thats not that hard either
Ah ok that's great
Timothy
Thanks
Timothy
Hi all, please help? I am wondering how to include uuid.h, when I have another header that already has uuid_t defined?
Dima
Welcome
Dima
Try to include it in different implementation files
Timothy
I only have one main file at the moment.
Timothy
I am trying to include this: #include <uuid/uuid.h> And use this function: uuid_parse
Timothy
Where’s your second header then?
It's a bluetooth header that I need.
Timothy
#include <bluetooth/sdp.h>
Timothy
Is there a way to only import one function from uuid.h?
Timothy
hmm so I used my common logic and copied the function from the header file into my main file, and renamed the conflicting type..... Probably very evil of me, but I'm keen to hear the "proper" way to do this.
Drew Diligence
better to steal the relevant code than import bloat // from <uuid.h>
🇰 🇷 🇦 🇹 🇴 🇸😜
Hi
🇰 🇷 🇦 🇹 🇴 🇸😜
Please can anyone send me the best book to learn nodern c++ something like c++17
🇰 🇷 🇦 🇹 🇴 🇸😜
Thanks
Biswajit
Hi
Shubham
Is there anyone in the group who done with cdac?
mark
un_known_
Ye kya h
un_known_
What is this.
mark
Its eeee
Anonymous
It's a demonstration of really cute usage of #include and #define to build a program that looks ridiculous below the region where the pre-processor directives would normally be
Foxner
Could one use whitespace unicode characters instead?
Foxner
Or would compiler not consider them as valid characters?