« first day (1608 days earlier)      last day (3355 days later) » 

5:00 PM
So who wants to work on an email client
This is incredibly annoying
 
@CatPlusPlus Not me.
 
@CatPlusPlus of course
twas a joke
 
@Mysticial Ah. I'll need to see if that fits my needs.
 
@R.MartinhoFernandes The vast majority of FFT uses can be padded out to the next efficient length.
 
@CatPlusPlus depends; ) do you have awesome job offer and ditto business plan?
 
5:02 PM
@CatPlusPlus So is making your own email client. slate.com/articles/technology/technology/2015/02/…
 
Projects started in this kind of places end up like tox at best
 
SJD
Hey. Somebody know what this warning means? > implicit declaration of function 'quit' is invalid in C99
 
Windowing function. Hanning ? Something with"black"?
 
@SJD Just remove line 34
 
@R.MartinhoFernandes Obviously, if you need 1025, and it needs to be padded out to 2048, then it isn't that efficient. So most (serious) implementations will support some non-two factors as well. The one in y-cruncher will do 2^k, 3*2^k, and 5*2^k.
 
5:03 PM
@caps lol going into email development without knowing anything about email
 
@SJD it means your code is trying to be wise, but the function to do so has not been declared
Include more headers
 
@CatPlusPlus I'll make you an email client if you make me a cross platform gui framework
 
SJD
Am I wrong? Have already included the following:
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <string.h>
#include <dirent.h>
 
@Pris QT
 
Go away
 
5:05 PM
@khajvah i want something more permissive
 
There's no 'quit' hth
@Pris Those already exist
 
You can't quit.
 
@SJD use the documentation. Not us
 
@SJD those are C headers... also quit is not a standard function en.cppreference.com/w/cpp
 
@CatPlusPlus They don't meet my specific requirements... sort of like email clients that already exist don't meet yours :p
 
5:05 PM
@CatPlusPlus I think he means 'one that works well'
 
What the fuck do you want from a GUI framework
 
@Pris Is qt really the only c++ cross-platform GUI?
 
@Jefffrey : Trust me. This is how it is in real code. — Shubhra Garg 2 mins ago
5
 
Both Qt and GTK3 work well
 
SJD
I see! thanks guys.
 
5:06 PM
I hope I never come across this place.
 
@khajvah More or less the one that has really good cross platform support
@CatPlusPlus permissive licensing :p
 
It's LGPL
 
Also it has to do all the OpenGL set up stuff for me
 
@SJD You probably meant the function exit from stdlib.h
 
@CatPlusPlus You're not supposed to use it for closed mobile platforms though
 
5:08 PM
Then use something like GLFW not a GUI framework
 
@chris That's the fugliest code I've seen this week:(
 
Let's write a gui framework then :)
 
lol closed platforms
 
@CatPlusPlus Not cross platform enough
 
lol mobile platforms
 
SJD
5:09 PM
@FredOverflow yeah I see. thanks. the point actually is that in somebody's program quit works fine (no additional headers or libraries included) ?!?
 
Use CEF
 
There should be html5 gui platform.
 
@khajvah I'm struggling to write one right now
 
@SJD Maybe they defined it themself.
 
@khajvah Awesomeium is html5 i believe
 
5:10 PM
@MartinJames You have seen worse? This is one of my all time favourites.
 
I never liked writing guis in C++. Gui should be in smth like html
 
That's because the GUI frameworks were designed long before the first C++ standard.
 
@Jefffrey I'm favouriting that one, for sure.
 
@CatPlusPlus Yeah its on my todo list to check that out. Tbh adding webkit or whatever just for a UI seems pretty bloat-y
 
~bloat~
 
5:11 PM
I think I'll actually upvote the question, because I just pity the guy.
 
Woah woah, don't jump on that, I don't really care about the bloat factor that much it was just a passing comment.
 
Too late
 
html5 GUI. I'm sure that will work really fast, just like X over a modem link.
 
More and more things are using that
 
I kinda wanna come up with a weird declarative syntax using c++11 only and not use a separate scripting layer
 
5:13 PM
Hi, a beginner here, I'm looking to check if a string contains a char (case insensitive). Google gave me a lot of complicated and/or outdated solutions. I'm sure this issue has been solved already somewhere, what could you advice me ? (also for later ignore accents, meaning that and éèëêÉ... could match an e)
 
@MartinJames Just the GUI, you gotta use your i7 somewhere
 
Use ICU
 
@chris Isn't it conceivable that would be a public/external function on a DLL, written that way to avoid DLL hell?
 
4
Q: Find if a string contains a character in C++ (boost allowed)

psycheSuppose I have a string and I want to find whether a specific character (like '|') is present or not, what is the best and fastest technique to do so? I know string find implementation.I am asking for even faster implementation than this one.

 
@Enissay Its a complicated question, there's no 'simple' solution. You need to use a library that handles case folding and stuff like ICU
 
5:14 PM
@caps No, it's just shit
 
@Enissay lol
 
@FredOverflow That doesn't even come close
 
> I'm sure this issue has been solved already somewhere
Promise me you'll never make this assumption for C++ code again
They have added standard threading support just a couple of years ago.
 
It's lame the if it's not :<
 
@Enissay Do you mean std::string or const char *?
 
5:15 PM
And we still don't have standard unicode support.
 
@FredOverflow How could THAT get four upvotes?
 
@FredOverflow find a char in a string
 
@MartinJames Simple: 5 people upvoted it, and 1 person downvoted it.
 
:\ I think I shall be picking up a pizza and booze on way home
 
if (s.find('e') != std::string::npos || s.find('E') != std::string::npos) std::cout << "Wanna buy an E?\n";
 
5:17 PM
@Enissay Case insensitive is relatively simple. The part about ignoring accents is not simple at all.
 
@FredOverflow Fuck me, six answers for 'look for a char in a string'.
 
@Enissay Maybe this, but it won't work with accented letters.
Or maybe this.
 
The Wupper is a right tributary of the River Rhine in the state of North Rhine-Westphalia, Germany. Rising near Marienheide in western Sauerland it runs through the mountainous region of the Bergisches Land in Berg County and enters the Rhine at Leverkusen, south of Düsseldorf. Its upper course is called the Wipper. On its course of about 113 km, the Wupper passes through the city of Wuppertal where the suspension railway runs for 10 kilometres above the river. According to a popular local story, on 21 July 1950 a young elephant named Tuffi jumped into the Wupper from the railway. It is crossed...
 
Supper
 
Maybe... a multimap of chars to all of their "equivalents". Then when the user inputs a char, the function checks the multimap at that char to see if any of the contents of the multimap are in the given string.
Not exactly simple. And you have to initialize the multimap with lots and lots of values.
 
5:21 PM
Or he could render the string and search for the e graphically ;)
 
@FredOverflow Haha, yes. Much simpler that way.
 
Well, all es look alike, no matter the accents, right?
 
λ toUpper 'è'
'\200'
Not sure if that's a good sign
 
Well, I'll leave teh accent part for later (must read more about that :>). For now Fred's solution is fine.
Thank you all guys <3
 
39
A: Check if a string contains a string in C++

codaddictYou can try using the find function: string str ("There are two needles in this haystack."); string str2 ("needle"); if (str.find(str2) != string::npos) { //.. found. }

haha awesome
 
5:25 PM
What kind of encoding gives '\232' for è?
 
@FredOverflow Haha, 2 minutes apart.
 
Oh wow, it's Unicode.
And toUpper works perfectly fine. Nice.
λ toUpper 'α'
'\913'
 
Xeo
Memo: If your string can correctly contain a certain character, do not split the string with that character as the delimiter. Fun bug.
 
guys is Hamiltonian Path = Hamiltonian circuit ? or Hamiltonian Cycle ?
ohhh .. so is circuit = cycle?
 
5:41 PM
Read here.
 
user1804599
How do you inject dependencies?
 
user1804599
:(
 
user1804599
Well if you're an addict you depend on it.
 
@райтфолд Reflection? Spring?
 
user1804599
5:50 PM
I see.
 
user1804599
Is Spring good?
 
@райтфолд Everyone is an addict.
 
Are forward declarations really required? Is there a reason the compiler can't 'leave' undefined symbols until all of the code it goes over conclusively has no definitions for the type?
 
@Pris Type checking?
 
6:01 PM
@Pris Technically no, they're not strictly required. Realistically, no you don't want to do without them though. Without them, a compiler could end up having to do a nearly arbitrary number of passes over code to sort things out. In something like C++, things could be substantially worse (to the point that I'm not sure it could be done without forward declarations, or at least the meaning of some things could change in their absence).
 
> For more details, please check the ticket 2042650 that we have
just created.
checks ticket
It's empty.
It literally has no description whatsoever.
 
Xeo
They just said that they created it, not that they filled it with useful info yet!
 
They suggested that it contains more details.
 
> An intervention has just been scheduled on [my server].
I have no idea what's happening.
 
Host? Work? What?
 
6:05 PM
Dedicated server. Personal.
 
lol I got 7$ back from Epic
 
@R.MartinhoFernandes Surgical?
 
The e-mail is titled "Ticket 2042650 - Anti-hack"
I'm confused.
 
Hetzner?
 
6:08 PM
Oh.
 
Also probably they detected something suspicious or whatever
 
I had to click on a button to show the actual description of the ticket.
Just opening the ticket was not enough.
 
> After that we went on a date and became a couple.
Romantic.
 
What does "Romantic" mean?
 
6:10 PM
@R.MartinhoFernandes The ticket was in an envelope.
 
I ran a port scan.
 
@Jefffrey I doubt you'll ever find out.
 
And they opened a ticket about it.
 
@R.MartinhoFernandes So what do they do, login as root and check for viruses?
 
@LightnessRacesinOrbit No, opened a ticket.
 
6:10 PM
@R.MartinhoFernandes Just opened a ticket?
 
@R.MartinhoFernandes Seems like a reasonable and responsible thing to do then.
 
They don't have a root access
 
Although it doesn't sound much like an "intervention"
 
@LightnessRacesinOrbit Is that a good thing?
 
6:11 PM
@Jefffrey No.
 
@LightnessRacesinOrbit Yeah, that bit scared me.
 
If this was OVH they'd probably take server offline immediately :v
 
@LightnessRacesinOrbit How so?
 
@R.MartinhoFernandes Presumably, an intervention was scheduled for some time in the future, to be performed conditional on your not responding to the ticket. (Otherwise why raise the ticket?)
@Jefffrey Extremely.
 
@LightnessRacesinOrbit They can't login as root. Well, they have physical access so they theoretically could do anything, but technically they don't have that kind of access; they would have to "somehow" obtain it.
 
6:13 PM
@R.MartinhoFernandes Perhaps the old concussive problem-solving approach
 
> Dear Customer,

We have detected unusual activity on your server [server name].

Feel free to communicate with our technical support so that this
situation does not become critical.

You can find the log returns from our system below that
led to this alert.

- START OF INFORMATION -

Attack detail : 4K scans
[...]
 
Or simply cutting you off from the network.
 
@CatPlusPlus It's OVH
 
@LightnessRacesinOrbit Do you think you can tell?
 
> - START OF INFORMATION -
lol
 
6:13 PM
Why are you in OVH
 
@R.MartinhoFernandes ahhhhh I knew it
@Jefffrey Yes.
 
@CatPlusPlus I've been for a while now.
Inertia.
I closed the ticket.
Other than opening this ticket, I have no complaints.
 
@LightnessRacesinOrbit Please go ahead
 
I wanted to port scan our work IPs and I accidentally ran the scan with /8 instead of /24.
 
6:15 PM
> To assess the quality of your ticket, you can complete the following satisfaction survey: [...]
 
ISPs don't like broad scans
You're lucky they just opened a ticket :v
 
@LightnessRacesinOrbit Did they get you to trade?
 
I was planning pizza and rum... end up with nachos and beer... en masse :\
 
Those are positive changes
 
very much so
 
6:20 PM
Hot hair for a cool breeze
 
though my half gone beer makes me think work is going to be extra hard tomorrow :\
 
@thecoshman Have a cigar
 
@Jefffrey o_0
 
dear boy
 
@R.MartinhoFernandes Surely you should communicate with them.
I was planning to have a night in and recover from last night. Maybe catch up on work. Then half an hour ago I decided to fuck it and go to the pub tonight. Now I've given up on both ideas, which doesn't even make sense. I think I'm going to order in some food though.
 
6:24 PM
@thecoshman Come on now
 
@Jefffrey no, dinner time :D
 
@thecoshman O.K.
 
mmmmmm so tasty
 
food suggestions plz
I almost feel like trying something new. Almost.
 
do they have good mexican food in hte uk
 
6:31 PM
not really
thinking of trying a Lebanese. I had really nice Batata Harra in a restaurant a few months ago and these guys have it
 
sure vOv
 
btw Shawarma looks like a kebab. it's just a kebab. what.
kebab on naan that is
 
greek/mediterranean?
 
wah £15 min order though
 
sure...
 
6:33 PM
suppose I could collect it but meh
 
or how about a really good burger place
 
ah £15 won't be a problem cos it's expensive
 
@Pris the only place I know you can get good mexican that's actually mexican and not tex-mex is Mexico
2
 
sure, why not
 
@Pris there aren't any really good ones that deliver
 
6:37 PM
yeah, out side of mexico is american style mexican
 
huh £16.20 is a lot to spend on a meal for myself on a Thursday night. I can't really afford this.
click
@thecoshman arseholes
 
call it what you like, I still like it :D
 
exciting
I almost never try new things
might even play a different Xbox game tonight
or if I'm feeling stupid I could splash out £45 on the full Forza Horizon 2 lol
 
@Jefffrey on, if you care
 
and not, if he doesn't?
 
6:44 PM
@Mgetz I've found a fair number of places near San Diego that serve what seems like pretty authentic Mexican to me (but for those of us who don't speak Spanish well, ordering can be difficult).
 
@JerryCoffin You're a wee bit closer to the border than I am. They probably exist in Denver too, but most are not well known to those of us that don't speak spanish.
 
Oops... yesterday was the BHF's No Smoking Day.
 
It's safe to sizeof(*foo) even if foo is an invalid pointer, right?
 
@thecoshman I'm too
Logging in now
 
@JerryCoffin Do they argue about immigration rights as you're eating them?
 
6:48 PM
Do you think university degrees are worth that much money?
 
@Maxpm yes, because sizeof is compile time
 
@khajvah It depends. Also, how much is "that much money"?
 
@Mgetz Thought so. Thanks.
@khajvah I think the degrees are, but not necessarily the education.
In the US, at least.
 
All of them cost a fortune. I used to go to university which was about $10k a year but it was shit.
 
@khajvah No.
 
6:50 PM
Haha paid education your country sucks
 
Now, I am transferring to try my luck somewhere else
@CatPlusPlus MIT is paid too ...
 
though my country does suck
 
@Mgetz I never ran into any in Denver that seemed even close to authentic. If you don't mind some driving (and the possibility of your car being stolen, etc.) Pueblo has quite a few places that are substantially more authentic.
 
@Maxpm I think I agree, but it depends there, too. The education you can get from, say, University of Phoenix, or some random State School, is not necessarily worth much. But a good liberal arts school can teach you a lot about critical thinking and "being human."
 
6:52 PM
@Puppy I'm not sure--my Spanish is barely good enough to order reasonably dependably; not even close to good enough to follow arguments about politics.
 
@CatPlusPlus What I mean is, nothing is free. Either you pay by taxes or you pay directly to the university
 
^ Episode VIII subtitle revealed
 
user1804599
@StackedCrooked Terrible.
 
Oui Monsieur.
 
6:54 PM
@LightnessRacesinOrbit You will never stop amazing me.
 
user1804599
@khajvah I'd say I'm pretty hot.
 
@khajvah Thanks hun!
 
user1804599
 
@StackedCrooked lol c plus plus
 
6:57 PM
@StackedCrooked lol, lame
 
user1804599
 
I don't get why @райтфолд has to follow up every conversation about my hotness with various "me too! me too! i'm a girl too! talk about me!"
lol "kom op dan" sounds like "come on then [m8]" but just means "come on over"? lame
 
user1804599
 
6:59 PM
Maybe she is?
 
@khajvah She seeks attention for it, though. I don't.
 
@LightnessRacesinOrbit Cmon, I like you more when you speak about games, star wars and c++.
 

« first day (1608 days earlier)      last day (3355 days later) »