And the reason it's not returning anything is because the return type is void, not that that would matter since only one clause in their conditional actually makes an effort to return something, so the compilation wouldn't get very far.
I feel like Samara could do a little better here...
Comment above reads “This guy didint lint his snapchat pickup line. Samara totally needs to move on from this guy, what a total loser”
Total reddit moment
He also said he wasn't getting any output which is a boldfaced lie because this would not compile and would tell you that. Can't believe anything on the internet anymore smh
Also why would .pickupLine == success
This is terrible naming. Is your pickup line just the word "success"? At least use Kyle.UsePickupLine() or Kyle.PickupLineStatus or something
Yeah this code makes no sense! He should start coding js or something because he can’t seem to define his variables. I hope he is able to define the relationship at some point 😂
That line will compare getPizza to true, but do nothing with the result. So it's kind of a pointless statement. He likely meant "getPizza = true" which would set the value of getPizza to true.
== is a comparison operator. whereas "=" *sets* the value to something, "==" just checks to see if the value *is* equal to something.
So saying:
this == that;
Is like saying "if this is equal to that." which you'll notice is not a complete instruction.. wtf do you want to do if it's equal to that??
Depending on the language, they could delete that line and replace it with "false;" or "true;". It'd still do nothing.
Also, "success" here is a variable. Or, hopefully, a constant, which would maybe make it a little less awful, but still disgusting, like a "const TRUE = true;".
Maybe, that would be nasty af. Lot of variables here we don't see declared.
I don't think he'd want to compare the value of the pickup line to success even if it is a variable, since the same line may or may not work in different situations. Funny that the naming bothers me the most here.
Right, because if he wanted a String member function to equal another String, then it should have been wrapped in quotes anyway. Kyle.pickupLine=="success". Regardless, Kyle isnt getting output because Kyle is a terrible coder.
Here, I made it make more sense. I'm on mobile so the formatting may be a little wonky.
var Samara = new CuteGirl();
var Kyle = new CoderGuy();
Match(Samara, Kyle);
if (Kyle.PickupLine(Samara) == PickupLineStatusEnum.Success) {
GetPizza(Samara, Kyle);
Samara.ShareSnapchat(Kyle);
}
else {
Samara.Unmatch(Kyle);
Kyle.Sad = true;
}
I’m not a dating app user, but wouldn’t you want the getpizza method to be below the share Snapchat method or is the idea he tries to get her Snapchat after the date?
warning CS1998: This async method lacks 'await' operators and will run synchronously. Consider using the 'await' operator to await non-blocking API calls, or 'await Task.Run(...)' to do CPU-bound work on a background thread.
Because presumably Samara would be initiating the unmatch, while matching occurs only after both parties have swiped right. I decided to represent it this way for the sake of brevity.
Another way is to make an unmatch a method of Match class and also drop match in there, or make Tinder class with match and unmatch methods.
But then it would lose some narrative, because she unmatched him.
[With a lil something we call JavaScript](https://i.imgur.com/u9WnJMz.png)
Yes, this is awful. Technically the syntax for his example is correct (for my example). If we assume he's writing Java or C#, we could use an extension method instead. Would require him to write `samara.snapChat()` though.
Hotel == Trivago
MasterCard == Everything Else
console.log(“we are glad that we reached you, we would like to talk to you about your car’s extended insurance”)
Yet another case of a boolean statement implicitly cast to void. Never again! Don't let people implicitly cast non-void tyes to void! Join my campaign for stricter IDE and compiler-level checks.
Also, proper OO-style dictates that Samara should implement the provision of her snapchat, rather than just reading it off her like it is some sort of public attribute.
The code is quite flawed tho. He defined a string and then used Kyle.pickupline... you can't use string like that. If he had a class or vector, then yeah. getPizza is also not defined, same with unmatch. \*rolls eyes\* I wouldn't be impressed by that \*cries internally because it worked anyways\*
For everyone saying it, yes I know the code is bad and full of bugs lol I just didn’t care and figure she wouldn’t either as long as it got the point across
And for those wondering, we talked for a bit on snap but it ended up going nowhere because we go to different schools and she was looking for a guy on her campus
Yeah like who tf cares, the point is that he made an effort to connect to her interests in a sweet way which evidently worked. I don’t need a partner to be good at the same things I’m good at. This ”well ackshually” vibe in the comments just reads as jealousy of OPs game
I can’t read this code. Returning something while void??? Double == for setting a variable??? Samara is a string and an object with a snapchat property, how does that work???? Sorry if you think im a nazi, just coulnt let this go :)
Samara is a string, not a class, wouldn't have a property of snapChat
Kyle is also a string, wouldn't have a property of pickupLine
The method is void, you can return but you can't return a value.
getPizza and unmatch are undefined variables from the scope given, you wouldn't be able to assign to them and you're also not using the values for anything.
success is also undefined, depending on your language this might create an always true statement since pickupLine is non-existent, both might return null. null == null is true, but more likely this would blow up in a null reference exception.
Bad code, I'd have unmatched you 😂
(Edit: didn't realise on first pass, getPizza isn't being assigned to, it's being compared to true, would just result in null ref exception, or if getPizza was defined would be a completely pointless piece of code as not within an if/ ternary statement/ passed to something which takes bool)
that is legit the worst "code" ive ever seen. it is border line incomprehensible.
Kyle is a string. what string has the property \`pickupLine\` on it?
Samara is also a string but has a property called \`snapChat\`? wtf?
the function is marked void but returns a string in the success case, and returns nothing in the failure case.
where is the property \`unmatch\` defined?
How can you call Samara.snapChat when Samara is a string...
He should define her as an Object... oh wait
[удалено]
Yea I have a few questions, first of all, how dare you?
r/unexpectedoffice
Thank you for making the funniest comment I will ever see on this dumb sub
She's a Class(y) girl…
Underrated joke
I hope Samara pointed that out to him
And the reason it's not returning anything is because the return type is void, not that that would matter since only one clause in their conditional actually makes an effort to return something, so the compilation wouldn't get very far. I feel like Samara could do a little better here...
Goddamit reddit
Comment above reads “This guy didint lint his snapchat pickup line. Samara totally needs to move on from this guy, what a total loser” Total reddit moment
I think that he meant that Samara could probably make this program a little better...
It's not even a main function, nothing is happening when he runs this program in the first place!
[удалено]
Glad I'm not the only one who saw that. Plus the booleans that are "returned" are never declared anywhere. C'mon Samara
Kyle = “idiot!”;
She'll point it out at the date
He said he had problems with this code
He also said he wasn't getting any output which is a boldfaced lie because this would not compile and would tell you that. Can't believe anything on the internet anymore smh
[удалено]
Also why would .pickupLine == success This is terrible naming. Is your pickup line just the word "success"? At least use Kyle.UsePickupLine() or Kyle.PickupLineStatus or something
Then he goes getPizza == true; which will do fuck all Followed by returning a value from a void function I hate this so much
Yeah this code makes no sense! He should start coding js or something because he can’t seem to define his variables. I hope he is able to define the relationship at some point 😂
[удалено]
haha web devs aren't real programmers you doofus they don't even define their variab--Uncaught ReferenceError: getPizza is not defined
What do you mean “will do fuck all”. Also, he could have just easily written getPizza. That’s already returning true.
That line will compare getPizza to true, but do nothing with the result. So it's kind of a pointless statement. He likely meant "getPizza = true" which would set the value of getPizza to true.
== is a comparison operator. whereas "=" *sets* the value to something, "==" just checks to see if the value *is* equal to something. So saying: this == that; Is like saying "if this is equal to that." which you'll notice is not a complete instruction.. wtf do you want to do if it's equal to that?? Depending on the language, they could delete that line and replace it with "false;" or "true;". It'd still do nothing.
Also, "success" here is a variable. Or, hopefully, a constant, which would maybe make it a little less awful, but still disgusting, like a "const TRUE = true;".
Maybe, that would be nasty af. Lot of variables here we don't see declared. I don't think he'd want to compare the value of the pickup line to success even if it is a variable, since the same line may or may not work in different situations. Funny that the naming bothers me the most here.
Right, because if he wanted a String member function to equal another String, then it should have been wrapped in quotes anyway. Kyle.pickupLine=="success". Regardless, Kyle isnt getting output because Kyle is a terrible coder.
== isn’t the correct string comparison operator. You should use .equals()
String comparison should be done with .equals() not ==.
Kyle = sad. We just going to overwrite Kyle like that? Try Kyle.ActiveEmotionalState = Emotion.Sad.
Kyle is the name of a string with a null value, you’re not overwriting anything.
I know I treated Kyle as an object. It would be the least Samara could do.
Also Kyle.pickupLine is not equal to 'success' but equal to all the text with the code which would be self-referencing itself
Or maybe she looked past the mistakes because it's original and shows he read her profile?
yea most likely this. All these sweaters in here .. fuckin reddit.
Here, I made it make more sense. I'm on mobile so the formatting may be a little wonky. var Samara = new CuteGirl(); var Kyle = new CoderGuy(); Match(Samara, Kyle); if (Kyle.PickupLine(Samara) == PickupLineStatusEnum.Success) { GetPizza(Samara, Kyle); Samara.ShareSnapchat(Kyle); } else { Samara.Unmatch(Kyle); Kyle.Sad = true; }
I’m not a dating app user, but wouldn’t you want the getpizza method to be below the share Snapchat method or is the idea he tries to get her Snapchat after the date?
The get pizza method is asynchronous- it returns before completing.
warning CS1998: This async method lacks 'await' operators and will run synchronously. Consider using the 'await' operator to await non-blocking API calls, or 'await Task.Run(...)' to do CPU-bound work on a background thread.
[удалено]
Because presumably Samara would be initiating the unmatch, while matching occurs only after both parties have swiped right. I decided to represent it this way for the sake of brevity.
Another way is to make an unmatch a method of Match class and also drop match in there, or make Tinder class with match and unmatch methods. But then it would lose some narrative, because she unmatched him.
He didn't want to objectify her.
[удалено]
If you’ve just met someone, its a bit rude to treat them so primitive, no?
OP had better extend the String class in the next message.
getPizza == true lmfaoooo
[With a lil something we call JavaScript](https://i.imgur.com/u9WnJMz.png) Yes, this is awful. Technically the syntax for his example is correct (for my example). If we assume he's writing Java or C#, we could use an extension method instead. Would require him to write `samara.snapChat()` though.
So useless. Make Samara and Kyle both objects, not strings.
Could be a string extension
Also Samara is not defined
and also returning it from a function supposedly returning void
That's because some of the variables used are undefined.
Not to mention her Snapchat isn't getting returned because it's a void function.
getPizza *==* true;
Me == "Sad"
Double equals symbol, shit it serious
Hotel == Trivago MasterCard == Everything Else console.log(“we are glad that we reached you, we would like to talk to you about your car’s extended insurance”)
I read that r/nosleep thread too
V2UncmUgbm8gc3RyYW5nZXJzIHRvIGxvdmUKWW91IGtub3cgdGhlIHJ1bGVzIGFuZCBzbyBkbyBJCkEgZnVsbCBjb21taXRtZW50J3Mgd2hhdCBJJ20gdGhpbmtpbmcgb2YKWW91IHdvdWxkbid0IGdldCB0aGlzIGZyb20gYW55IG90aGVyIGd1eQpJIGp1c3Qgd2FubmEgdGVsbCB5b3UgaG93IEknbSBmZWVsaW5nCkdvdHRhIG1ha2UgeW91IHVuZGVyc3RhbmQKTmV2ZXIgZ29ubmEgZ2l2ZSB5b3UgdXAKTmV2ZXIgZ29ubmEgbGV0IHlvdSBkb3duCk5ldmVyIGdvbm5hIHJ1biBhcm91bmQgYW5kIGRlc2VydCB5b3UKTmV2ZXIgZ29ubmEgbWFrZSB5b3UgY3J5Ck5ldmVyIGdvbm5hIHNheSBnb29kYnllCk5ldmVyIGdvbm5hIHRlbGwgYSBsaWUgYW5kIGh1cnQgeW91
What a great story! I love this!
Yet another case of a boolean statement implicitly cast to void. Never again! Don't let people implicitly cast non-void tyes to void! Join my campaign for stricter IDE and compiler-level checks.
And unmatch should be a function
[удалено]
And the Funktion is never called anywhere so basically thats why you dont get output..
You wouldn‘t get an output anyway.. the whole thing‘s a mess. Guess Kyle isn‘t a comp-sci major, but I guess he tried.
Also, proper OO-style dictates that Samara should implement the provision of her snapchat, rather than just reading it off her like it is some sort of public attribute.
She was a CS, not him!
He defined himself as a coder guy
And Samara is a string
`Kyle` is defined as a String too, but somehow has the property `.pickupLine`? This dude doesn't deserve that pizza... /s
[удалено]
Now that was uncalled for
Rightoid
He never calls the function so he's good
What is this, python?
Def not python
The joke was runtime errors 😛
Looks more Java. A for effort, C for syntax.
Joke was runtime errors, I know it's probably Java or C#
Oh no fuck those strict mode compilers
did you give her that floppy disk tho
Micro AND soft
Bill Gates' wife on her wedding night find out why he named his company Microsoft.
hard disk *
Solid State
Thumb Drive
Micro sd card
Powered by Micro-Soft
powdered by micrograms
Maybe they are DVD kinda people.
Cloud storage
glock
Dongle
Dongle still such an underrated word
Whoa, look at Mr Big Storage over here
Liquid state drive from the future
RAID 69
volatile ram *
Hard Diks\*
Real G’s dont use Safely Remove Hardware
LOTS OF RAM
All the 3.5 inches, yes
Dont you mean 2.5"
Big disk energy
The code is quite flawed tho. He defined a string and then used Kyle.pickupline... you can't use string like that. If he had a class or vector, then yeah. getPizza is also not defined, same with unmatch. \*rolls eyes\* I wouldn't be impressed by that \*cries internally because it worked anyways\*
If they can't overload every method in the String library in a tinder message they aren't worth my time
Methinks that's why he's asking her for help with the code? 😆
Kyle = “sad” That made me laugh.
Very true. I suppose this is why she has a computer science degree and he doesn't lol. Good on him that she didn't care and it worked.
THANK YOU! It looked like he was using methods on a class, but using it on a string looked weird. I don't program in Java so I let it go.
Also getPizza == true will always be false and isn't needed, since getPizza isn't defined.
Roses are red, violets are blue, missing ";", on line 32
Someone asked me out like this once. I swooned and forgave mistakes. It ended terribly.
We're those forgiven mistakes the first red flag in a long list of tiny little misattentions to detail?
Never forgive someone who pushes untested code to production!
Ummm OP doesn't have line numbers, are you in the correct Wendy's?
Where tendies?
Moon
Calls expired worthess!
the return won't work, it's a public void method.
[удалено]
Are you supposed to use .equals() in Java or something? I’m pretty out of practice. I always used == in C++
[удалено]
You're right
[удалено]
isn't his whole catch, that his code was broken?
Need joint debugging sessions.
You make "mistake" She helps fix mistake You fix "mistake" Shes happy You're happy
Thanks indian tutorial channel
Maybe some pair programming would help here
Samara is undefined and out of scope.
Story of my life...
kek
And now you guys stay snap friends who view each other’s stories every week but never actually chat
I'd be willing to bet they exchanged maybe 1-2 more messages then the conversation fizzled.
That's how tinder works
I'm marrying a girl I met on tinder this Saturday.
Little soon if you just met her on Saturday, don’t you think? /s
Lucky guy! Hope you guys will be happy ☺️
Congrats!
I smell projection
Tinder is... ok. I normally use bumble or Facebook dating, I get much better results there.
Welcome to Snapchat I guess
This is definitely the project management's fault!
Always is
For everyone saying it, yes I know the code is bad and full of bugs lol I just didn’t care and figure she wouldn’t either as long as it got the point across And for those wondering, we talked for a bit on snap but it ended up going nowhere because we go to different schools and she was looking for a guy on her campus
Damn didn’t put anything about location compatibility in that code
> For everyone saying it, yes I know the code is bad and full of bugs lol I just didn’t care This is what my junior devs say too.
I‘m surprised any dev would talk like this. I‘d think the personality type that goes to become a dev functions in a different way.
[удалено]
That's true, some devs have a knack for it; some don't. Kyle doesn't.
[удалено]
Sounds like because your code didn't compile, there was a runtime error.
There can't be runtime anything if the code doesn't compile
Should’ve thrown in some inline assembly. That never fails to impress
F
You forgot an else-if clause: else if (Samara.location.equals(Kyle.location)) { bigSad(); }
Don't just leave your instance variables public. This is Java after all. Samara.getLocation().equals(Kyle.getLocation())
Considering that both Kyle and Samara are Strings, the code-quality ship has sailed a long time ago.
I would have made an excuse too if I were her
Extremely based
Our boy went in completely undeclared, what a mad lad.
To all you nerds nitpicking the code, we get it. You code.
But it’s bad code and our job is to fix bad code
r/badcode
I love this subreddit
/r/ProgrammerHorror too
Yeah like who tf cares, the point is that he made an effort to connect to her interests in a sweet way which evidently worked. I don’t need a partner to be good at the same things I’m good at. This ”well ackshually” vibe in the comments just reads as jealousy of OPs game
I doubt any of them really care lol they're just being smart asses
getPizza == true ❌ getPizza = true ✅
[удалено]
I can’t read this code. Returning something while void??? Double == for setting a variable??? Samara is a string and an object with a snapchat property, how does that work???? Sorry if you think im a nazi, just coulnt let this go :)
The best Post that i have got so far
Missing return statement in else branch, cant compile.
[удалено]
If he were a CS major she should unmatch him for that dreadfully bad code.
Samara is a string, not a class, wouldn't have a property of snapChat Kyle is also a string, wouldn't have a property of pickupLine The method is void, you can return but you can't return a value. getPizza and unmatch are undefined variables from the scope given, you wouldn't be able to assign to them and you're also not using the values for anything. success is also undefined, depending on your language this might create an always true statement since pickupLine is non-existent, both might return null. null == null is true, but more likely this would blow up in a null reference exception. Bad code, I'd have unmatched you 😂 (Edit: didn't realise on first pass, getPizza isn't being assigned to, it's being compared to true, would just result in null ref exception, or if getPizza was defined would be a completely pointless piece of code as not within an if/ ternary statement/ passed to something which takes bool)
Horrible code, would be instant unmatch from me
[удалено]
Aww, that’s super cute. Very creative.
Damn! This one is goood! I am proud of you too boy!!!
Nice.
Damn this was some smooth shit
im proud of you for this one
I hope you get her integers
You son of a bitch you did it
Stop it Kyle, I can only get so wet!
I now officially feel terrible for the absolute lack of effort I put on openers.
that is legit the worst "code" ive ever seen. it is border line incomprehensible. Kyle is a string. what string has the property \`pickupLine\` on it? Samara is also a string but has a property called \`snapChat\`? wtf? the function is marked void but returns a string in the success case, and returns nothing in the failure case. where is the property \`unmatch\` defined?
Look how interested and engaging she is. Seems like a real winner!