2foryou
ok thanks, I will check poco . well for example parallelizing mergesort might be benefitial I now am reading this one http://penguin.ewu.edu/~trolfe/ParallelMerge/ParallelMerge.html where you can see difference in time I know maybe its not the best way to speedup the program but I 'll check other functions other than sort later
Dima
Telegram team is currenly looking for c/c++ software engineer at @jobs_bot , if anyone is interested
Dima
this is official
BinaryByter
*applies*
Dima
@QNeko I remember you was talking about decentralized distributed servers/clusters, how come servers see each other if its decentralized?
BinaryByter
BinaryByter
oh no ;_;
BinaryByter
xD
Dima
wat
BinaryByter
test task
BinaryByter
lol
Dima
did you apply for c++?
BinaryByter
yep
Dima
wtf it didnt tell me for task
Dima
just like “we will review it"
BinaryByter
Lol
Dima
rip
BinaryByter
lets hope they are fine with hiring a 15 yo weirdo xD
Dima
can you pm or whatever the options you selected to me? I am curious
MᏫᎻᎯᎷᎷᎬᎠ
BinaryByter
I mean
MᏫᎻᎯᎷᎷᎬᎠ
I'm a software crapper :D
BinaryByter
according to signaling theory i have a pretty high chance of getting into a closer sleection
MᏫᎻᎯᎷᎷᎬᎠ
I can make classes lol
BinaryByter
I can make classes that you can only instantiate once >:D
MᏫᎻᎯᎷᎷᎬᎠ
BinaryByter
no lol
BinaryByter
using a private constructor
BinaryByter
or one marked deleted
MᏫᎻᎯᎷᎷᎬᎠ
How
BinaryByter
you make a static factory method
MᏫᎻᎯᎷᎷᎬᎠ
You said instantiate once
BinaryByter
You said instantiate once
you litterally can only have one single instance of that class
BinaryByter
at once
MᏫᎻᎯᎷᎷᎬᎠ
I think I get it
BinaryByter
thats what you call a singleton
BinaryByter
you use that for example for database connections
BinaryByter
in order to make sure that there is only one instance
Javier
S -> A | AA | AAA A -> ABa | ACa | a I need help. I have to read that kind of input from file, but I just wanna put the strings after "->" into each position of a vector. For example, with the first one, the vector should contains: v[0] = "A" v[1] = "AA" v[2] = "AAA" I've done this but it's not working: for(size_t i = 0; i < nsymbols_.size(); i++) { is >> (char &) current_symbol; is.ignore(256, '>'); std::getline(is, line); auto n = std::count(line.begin(), line.end(), '|'); for(size_t j = 0; j < n; j++) { size_t pos = line.find(" | "); prod = line.substr(0, pos - 1); line.erase(0, pos); v.push_back(prod); } v.push_back(line); }
BinaryByter
and then you consume the string result
Ludovic 'Archivist'
@QNeko I remember you was talking about decentralized distributed servers/clusters, how come servers see each other if its decentralized?
Decentralized doesn't imply there is no consistency, it implies there is no master/slave behavior nor central point of failure
Ludovic 'Archivist'
@QNeko I remember you was talking about decentralized distributed servers/clusters, how come servers see each other if its decentralized?
For example, Google Spanner is decentralized yet all the servers communicate to ensure consistency
BinaryByter
but what does it do?
BinaryByter
just give some ips?
Ludovic 'Archivist'
so theres still an intermediate server?
No, all servers are generally identical on a decentralized system
BinaryByter
how can my client know whom to talk with?
Ludovic 'Archivist'
BinaryByter
or how can one server know whom to talk with?
BinaryByter
Any of them is fine
but how do you find any of them?
Ludovic 'Archivist'
or how can one server know whom to talk with?
Each server may know the layout of the system
Ludovic 'Archivist'
but how do you find any of them?
You ask your nice sysadmin like anyone
BinaryByter
lets say my layout it outdated
BinaryByter
what does my system do?
Ludovic 'Archivist'
lets say my layout it outdated
Try to find one server you can connect to to ask for the layout
BinaryByter
Oh
BinaryByter
what if the whole layout changed?
BinaryByter
how does a cold boot work?
BinaryByter
like. at first you dont have a layout at all
Dima
So there’s a list somewhere of all servers anyways? Like @maxi noted ips or whatever I am kinda getting lost imagining how come they should communicate without knowing addresses
Mihail
Why shouldn't they know addresses tho?
Mihail
As long as they all have the same knowledge about those addresses it won't be centralized
BinaryByter
how do they update their list?
Mihail
how do they update their list?
Just look at any of the others?
Mihail
They're all the same after all
BinaryByter
Just look at any of the others?
what if their list is completely invalid?
Mihail
Maybe they can tell the one asking them if their own needs a sync
Mihail
But then idk how they'll know
BinaryByter
Maybe they can tell the one asking them if their own needs a sync
again: what if their list is COMPLETELY invalid?
BinaryByter
not one single server is still valid
BinaryByter
which is possible in networks with 2-3 servers
Mihail
not one single server is still valid
In that case what do you expect?