« first day (1182 days earlier)      last day (3133 days later) » 

13:00
Great question! Working code should probably be migrated to our sister site, codereview.stackexchange.com . — rajah9 16 secs ago
Hello @SimonForsberg @Gemtastic
I'm not enjoying all the work associated with redesigning my database :P
hi guys! how can I get this (cut by a line effect) for a code in my answer
---String str = "can you help?";----
@CrazyNinja For code? Put HTML tags around it
<strike></strike>
I think
13:02
@syb0rg THanks!!!
Zak
Zak
@CrazyNinja In-code markdown requires HTML (I think)
So how would you markdown HTML :P
@syb0rg just s is sufficient :D
<strike>
2
Using HTML on the HTML inside an HTML page inside an HTML view - my head hurts
13:04
@Vogel612 Didn't know that, good to know
@Trojan404 I've had worse ..
Yay! I made it :)
0
A: Merge sorting a singly-linked list in Java - follow-up

Crazy NinjaI think, toString() in LinkedListNode.java could be refactored. Let's just keep things simpler. (^_-) public static <E> String toString(LinkedListNode<E> head) { final StringBuilder sb = new StringBuilder().append('['); LinkedListNode<E> current = head; if (current != ...

@syb0rg ^
hard to read
@CrazyNinja You could just remove that code lol
13:06
Don't actually recommend that style of answering, it's better to show "old" and "new"
Typically that's the better way to do it ^^
@syb0rg I thought reader will easily grab the piece of code what I'm talking about directly
@CrazyNinja The first block is the OP's code, correct?
Should I want to remove strike effect?
Striking through code is better for a one line joke effect
also... technically the first and last lines were correct?
13:07
@syb0rg the code which has striked is OP's method
if you want to compare against the old code I'd recommend using quoted code
Anddddd lastly,
your answer seems to be a rewrite without all that much explanation =)
@CrazyNinja Here's what you should do to get my upvote: 1. Remove the OP's code from your answer, you already mention the place in his code you're fixing; 2. Give a better explanation as to why you're refactoring is better
because I have a counter point already
and that's performance
@syb0rg let me try :D
13:11
@Pimgd Yes, there has been an answer on meta about this I think, 5 minutes or so?
Oh, 4 hours.
0
Q: Learning classes php

TropusI'm working on improving myself by teaching myself how to make classes to remove reppetitive pieces of code and create a class that does it for me. I have made the following class and would like to know what I could do better and possible concerns you see. class CustomImportClass{ private $...

@Mast yes, I thought "no grace period" at first, but 4 hours is pretty close to "no relevant grace period, unless you were being an evil haxor"
... and a good old stack overflow. (^_-) — coderodde 1 min ago
oooh
I think tail-call optimization will take care of that but I am not sure
so yeah, 1 million items, you could definitely get a stackoverflow
@CrazyNinja And a fix for the stack overflow now ;)
(and that's not the website)
If your code runs without error, then kudos on you, but you might want to post on Code Review. — Tim Biegeleisen 26 secs ago
13:15
@Pimgd Nods. No args on that. Performance will have an impact
so yeahhh lemme know when you've fixed those things, because right now it's a detrimental answer
Code review questions are probably better suited to codereview.stackexchange.com. — T.J. Crowder 44 secs ago
@Pimgd java doesn't generally do Tail-Call optimization, which is bollocks. Java should do tail-call optimization ...
Should I remove my answer?
just fix it, that's usually better :)
13:18
@CrazyNinja No, you should fix it.
@CrazyNinja Perhaps temporarily? You can still edit it while deleted and then undelete it
@Mast But I know that @Pimgd is correct
Just fix it. It will be fine in the end.
10 mins ago, by syb0rg
@CrazyNinja Here's what you should do to get my upvote: 1. Remove the OP's code from your answer, you already mention the place in his code you're fixing; 2. Give a better explanation as to why you're refactoring is better
@CrazyNinja Do a bit of research, find a better way
You could pass a string builder along?
13:20
@syb0rg thanks for that Motivational words! :D
that'd fix the stringbuilder issue
you'd just be left with the stackoverflow...
@CrazyNinja Well this is what makes you a better programmer, no?
Reviewing other people's code is a challenge
@syb0rg I'm new here, I find you guys are cool! yes. I'm getting to learn lot of things
4
Code Reviews take a while, and with lots of code your question could take a few days to be answered even — syb0rg 10 hours ago
Whoever gave some upvotes; thanks a lot dude ^_^ <<thumbs up>>
13:29
blehhhh edit conflict
0
Q: Angular2 sortable lists (using typescript)

NirI wrote a simple and small projects that present 3 buttons, each one loads a different list to the screen on the same place but not in the same time. in my html I think I can maybe use some more generic way to present the lists: <div> <!-- list 1 button --> <button md-button (cli...

@Pimgd Op, sorry
Time to go home, otherwise I might miss my last bus to go home
Catch u guys later!
@CrazyNinja Bye!
How's it going guys?
13:32
HRNGH. ... PEOPLE ARE STUPID
 if (duplicateKey != null)
 {
   System.out.println("Error - Duplicate component name");
 }
^^ found in a question ...
friday night, these corn chips are nearly as salty as my teammates
@Quill league or dota?
@Vogel612 I thought that was a given?
HoN :D
@DanPantry counter strike
13:34
The "offensive" part in the name is pretty accurate
4
oh that's right - the CS:GO tourny is tonight
Perhaps I should edit my question dramatically, or move my question to the Code Review StackExchange? I don't want to put too many lines of code into my question, I don't really want debugging help. All I want to do is understand why the 2nd index in the CharArrayXY[5][65] line of my console output is [65] instead of [0], which is what it was before the realloc() command was called. — Vladislav Martin just now
No problem, I find it hard not to agree with myself — forsvarir 37 secs ago
... teehee
@VladislavMartin It's not about how many lines of code you want to include. It's about how many lines people need to answer your question. Not including it all means they can't. And why would CodeReview be any more willing to review incomplete code? Anyway, if you're doing anything that invokes UB, then that's why weird things are happening. — underscore_d 32 secs ago
0
Q: Html rendering framework with dynamics

t3chb0tI came to the conclusion that the previous framework was too complicated and not easily extendable so I tried it again but this time with dynamics. It's much much shorter and I think it's much easier to extend it now. Core The main part of the new framework is the MarkupBuilder that is deriv...

0
Q: How can I make the alphabets entered (through scanf) interpret as integers the way it's defined in an enum? Please have a look at the program below

B. BhargavI am trying to make a C program for converting a given number in say base x, to base y. I chose to narrow it down upto base 20 (i.e. Base 2 to 20). When it comes to scanning a hexadecimal number (includes ABCDEF too, right?) for example, I am stuck. Please look at my program below: /* NOTE: This...

> top top bottom:
This might be better to post a code review instead of here. FWIW I do not see anything unsafe. — NathanOliver 8 secs ago
Zak
Zak
regex is hard :(
ftp site doesn't work - ssh and tls not working, can connect via insecure, all users don't work except root user...... at least we can still connect? lol
13:42
@Zak latest RD release includes the Regex Assistant
> And why in gods name do you rely on names?
Lol
it's like relying on employee's firstnames for a unique constraint ...
@CaptainObvious Ugh go away
@CaptainObvious mc21vd
@CaptainObvious printf("WANNA DO IT AGAIN?
13:48
@NathanOliver I'm not familiar with "code review", but I will google that out. — nekitip 41 secs ago
We're ragging on this one for the lulz, right?
Zak
Zak
YES!
@Zak Regex is not hard, it is witchcraft / black evil magic.
@Zak I'm not sure you're using regex right here...
13:51
@Zak what's that monster ?
@Zak Please stop! Think of the children!
actually... think about your brain, make it easier on yourself and use String.Split
Zak
Zak
Don't worry, I'm not about to just copy/paste that monstrous string into my project.
@Zak if it looks like vomit, smells like vomit, tastes like ...
Zak
Zak
It was actually procedurally generated ^^
13:52
... then it must be regex.
Zak
Zak
(I understand you might not think that's a good thing...)
I mean, orange with green chunks in it...?
@Zak ... look ... don't use regex. it's not meant for things like this.
@Zak if for any reason somebody wants to troll you... it's enough to put a . somewhere. Happy debugging time ^_^
13:53
@Dex'ter Version control
@Zak How to drown in pings, say you like to use regexp in chat.
@Pimgd dat edit summary
bisect + blame = "Look, this is very funny, but you'll be doing overtime on saturday without pay to make up for lost time, okay?"
@NathanOliver No, this is not a good question for Code Review. Please see what is on-topic over there for an explanation as to why. — syb0rg 29 secs ago
0
Q: Optimize finding the Nth occurrence of character in string

jklI wrote a sql server function which returns substring before the Nth occurence of character. For example, SELECT dbo.fn_getFirstNthSentence('.', 'hello world.It.is.raining.today', 3) returns 'hello world.It.Is.' as a result. The function I wrote looks dirty and slow so I want to optimize it. An...

13:54
@Pimgd git commit vomit regex
hehe
right... less vomit, more actual code talk...
=D
> I went through this answer and fixed what I found, but I forgot what I found so I can't really type a proper edit summary =/
Basically I wish I could diff my edit before I submit it
22
Q: My employer (client) wants me to work in “ghost” mode

Mik378Here's the context: I'm a freelance architect/developer and have started working for a known company 3 weeks ago, for at least one year. They recruited me because they completely failed on a project during 6 months (an hybrid mobile application) and their customers are very angry because the...

Beware the programmer of codebase-past, for he will haunt you with terrible curses such as if(false)
Zak
Zak
@Pimgd My answer had +3. I go away for 20 minutes and suddenly it goes to +15. I assume it went HNQ.
15
A: My employer (client) wants me to work in “ghost” mode

ZakGet everything in writing The client wants to hire you to do a job. They want you to do it under unusual and technically-challenging conditions. These conditions are unusual, possibly unethical (for the managers) and carry significant potential risk for you (mostly reputational, possibly leg...

0
Q: Accepting user defined functions for custom map reduce functionality in C++

jrammI am implementing map and reduce - style functions for processing geospatial raster datasets. I would like the map and reduce functions to accept a user-defined function as an input which will be applied to the raster dataset. Currently I am using function pointers - is this a good starting poin...

14:10
Yay, StackExchange has NSFL questions too!
10
Q: A method to cause maximum pain to a human

MedwedianPresidentI am currently searching for a new execution method to be used in my fictional psychotic dictatorship. After introducing methods such as decompression, boiling, surgical torture (being dissected alive without anesthesia) or slow dissolution in acid, the dictator is still not satisfied, saying tha...

(which is why I'm linking to them, ofc.)
@syb0rg Your answer looks very interesting, but it does not reply to my question. I'm asking: "Do you think this is a correct implementation of a Siamese neural network with cosine similarity function to minimize?" Do you think it is or not? Thanks — DavideChicco.it 3 mins ago
Uhh...
So you aren't asking for a review?
@syb0rg just add a line "I think it's great, but it could do with a few improvements" or something like that - depending on the answer to that question, ofc.
I just launched my current C++ project in Visual Studio because I couldn't figure out the bug without it. Now I feel dirty...
@syb0rg Ouch.
@DavideChicco.it Well yes, but you do understand the point of Code Review is to improve the code, right? You are supposed to verify it is a correct implementation yourself. — syb0rg 1 min ago
@Mast gdb? Or is this all on Windows?
Zak
Zak
And there's my Workplace mortarboard for today.
14:18
@syb0rg No, it used to be Linux-side.
@Mast Did you try using gdb? Granted it can be kinda daunting to use at first
retagging spreee
@syb0rg I tried ddd, but I'm not sure I should continue that route.
Hmpf, I suspected as much, the function was doing a whole lot of nothing. The data it's supposed to be iterating over is corrupt.
possible answer invalidation by BruceWayne on question by BruceWayne: codereview.stackexchange.com/posts/136225/revisions
Oh, and I made VS crash.
Nothing new there...
Back to Ubuntu it is...
14:29
and done with retagging spam
> // IGNORE THIS.
Okay
Zak
Zak
0
Q: Regex Matching a Naming Convention

ZakProgram Purpose So, I have a naming convention for certain folders. I want to take in a folder name, and determine if it conforms to the convention. Naming Convention The convention (case insensitive) can be as simple as "Surname, Firstname" It could be as complicated as "Surname ...

Now you can channel your regex hating constructively ^^
@Zak I shoot tiny reviews at youuu
And please tell me it's not a silly type cast
because then I'm gonna go club VBA
Zak
Zak
@Pimgd Nope, you're absolutely right, it makes more sense that way.
@Pimgd Club VBA sounds fun, wonder how expensive the drinks are
4
@Quill depends whether you want them with or without splinters
14:40
0
Q: Producer-Consumer

lanyhi i have some problem in my code and i don't know why it breakdown at some point. can anybody please correct my mistake i need a multithread program and it's my first time writing it #include <iostream> #include <queue> #include <thread> #include <condition_variable> #include <mutex> using name...

4
Q: Regex Matching a Naming Convention

ZakProgram Purpose So, I have a naming convention for certain folders. I want to take in a folder name, and determine if it conforms to the convention. Naming Convention The convention (case insensitive) can be as simple as "Surname, Firstname" It could be as complicated as "Surname ...

@Quill They're free if you buy something really expensive, but get the scotch. 20 year old beer or wine isn't nearly as good.
also, @Zak, ... we talked about this before, right
A tussenvoegsel (pronounced [ˈtɵsə(n)ˌvuxsəl]) in Dutch linguistics is a word that is positioned between a person's first and last name similar to Irish or Scottish surname prefixes, French particules or German von. The most common tussenvoegsels are "van" (as in Vincent van Gogh; see also van (Dutch)) meaning "from" and "de" (as in Greg de Vries), meaning "the". Other Dutch surnames include no tussenvoegsel (as in Mark Rutte and Wim Kok). The use of tussenvoegsels differs between the Netherlands and Belgium. == In the Netherlands == In the Netherlands, these tussenvoegsels are not included when...
Zak
Zak
@Pimgd Don't blame me, blame the business logic.
No, you're not assertive enough.
Blame the Dutch!
2
14:49
@N3buchadnezzar were you looking for me? it's Friday you know?
Actually, this can work just fine with other delimiters (though doing some is somewhat ugly). You create a ctype facet that classifies the desired delimiters as whitespace, create a locale containing that facet, then imbue the stringstream with that locale before extracting strings. — Jerry Coffin Dec 19 '12 at 20:30
Nonononononono
> somewhat ugly
Do not go around re-defining whitespace, that way lies madness.
@Mast What.madness.are.you.talking.about?
=/ no functional programming for arrays in Java
GitHub is really making a mess with UnrealEngine source repo, I'll see if I can find some news report on it
14:58
ugh, Feliks broke like all the rubiks cube records in the EM finals > . <
I wanted to do magic stuff with enum.values().filter(predicate)
@Malachi Yeah, just wanted to inform you that it was Friday.
I am very happy that it is Friday, it has been a long week
Yeah, think it's been about 7 days.
no more like 10
15:00
scratches head
What you get for skipping the weekend.
More pay
"Man wants to jump from 7.5km height into safety net" - "Don't try this at home"
@skiwi Would have to buy an awfull lot of ladders to attempt that at home
Zak
Zak
Apparently, my regex is only 518 characters long ^^
15:09
'why is the frontpage filled with hackerrank?
@N3buchadnezzar hackers have taken over the site
@Pimgd Blame Pimgd!
@Pimgd @N3buchadnezzar It's because of this
@Pimgd Seems like you have been a busy bee editing tags.
There are a number of ways you could do this. I would suggest maybe sending your code to Code Review to have it looked over. — Gary Evans 1 min ago
15:17
0
Q: Find the 10001st prime number (in C++)

syed saad#include<iostream> #include<bits/stdc++.h> #include<climits> #define max 500000 using namespace std; int main() { int ctr = 0; int i=2,j,n=10001,p=2; int arr[max]; memset(arr,0,sizeof(arr)); while(1) { p=2; while(p*p<=i) { if(arr[p] == 0) for(j=p*p;j<=i;j+=p) arr[j] =...

@CaptainObvious looks like alllll the standard answers apply here
@Pimgd Lint that sucker!
braces, indentation, using namespace std...
practically the only thing missing is return 0
15:21
@Pimgd Did i show you the mad libs question?
I don't know
how can you paste something like this into your stackexchange description ?
1
Q: Mad Libs program

PLP123My code creates a Mad Libs program. Its a prewritten story that you fill in blindly. There are 4 pages of 7 entry boxs and labels. When the inputs are in and next is pressed it saves inputs as variables that it puts in the story and changes the labels. When all blanks have been written in. An inf...

@Dex'ter codereview.stackexchange.com/users/YOURID/YOURNAME/flair
@Pimgd just paste it like this ? ^^
15:24
@Pimgd it should even work with this link
aww
it works without theme for autoboxing
nvm it doesn't ...
but I wanted to make it hotdog (mainly because it looks awfully bad =D)
/tmp/cckgNvFt.o: In function `main':
main.cpp:(.text+0x3c3): undefined reference to `ituCountry::ituCountry(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >)'
Very helpful...
15:26
=D
@Pimgd Start linking.
loool..
@Mast tell that to @Community
lol
Community doesn't need flair.
the regular one works just fine
But that's no fun
@Mast yay templates
15:27
I got 100 rep just for being a trusted user-. I do not trust that one bit :p
I could get my network rep up by a ton just for joining random sites
@Pimgd For some values of template, it's a struct.
@Pimgd Yup, 100 per site. There's probably over 100 sites, so that's 10k free rep.
> Each of our 157 communities is built by people passionate about a focused topic.
15:29
15.7k rep.
I'm only just over 10k, guess I need to join more sites.
OTOH, what's the point.
I should make a script so that I join a random stack exchange site each day.
It doesn't increase anything.
So that I do not rouse too much suspicion.
They don't care.
... chatflags?
15:30
I somehow remember that association rep doesn't count for network rep
Network reputation is one of the least relevant stats.
sooo... no chatflags for you :D
Oooooh, so that's why I can see chatflags nowadays.
@Mast I care! SNIFF
I passed the threshold.
15:31
Yup. it's really enjoyable, right?
So far I don't see them often.
I still remember the flag I got about the russian bunny, still weirds me out.
can someone please explain why I have repeatedly said "put all changes in source control" and once again someone has committed half a change without the sql script so now my environment is broken..
ffs
@DanPantry Get another job.
Oh, wait.
Zak
Zak
huh. I'm only about 300 rep off of seeing chatflags.
15:33
ffs.
I'm really, so mad right now
wait... didn't you race for 10k?
@Zak ¨Join 3 random sites =D
@DanPantry can you escalate the problem?
or rather. ...try to find the root cause...
Zak
Zak
2 mins ago, by Vogel612
I somehow remember that association rep doesn't count for network rep
are the sql scripts somewhere that's hard to version=?
15:34
@Mast I just summed your rep - it's 20809
heh, now I have that flairy thing on profile. It looks quite awesome
Root cause is pretty well known.. the person in question refuses to learn new tools... we have a tool for versioning sql scripts, he refuses to learn it.. so everyone has to adjust their workflow around it.. same thing with the git cli
but chat says 10.1k
count = 107, so -10.7k ...
yeah, the 100 bonus rep doesn't count.
Zak
Zak
@DanPantry This would be something that you escalate to your manager?
possible answer invalidation by Sam Orozco on question by Sam Orozco: codereview.stackexchange.com/posts/136275/revisions
15:35
i'm going to take the weekend to think about it and if i am still pissed i'll raise it on monday
WOW! how many globals can you guys count ? ^^
but if I sum it with each -101,
Zak
Zak
Like, this is literally the point of managers, to handle conflicts that cannot be resolved between the people involved.
then the total is 10002.
Yet chat shows 10.1k.
So the 1 rep from joining a site DOES count.
So yay, you can get 1 rep per site!
@Duga rolled back and commented
15:38
Then again, joining all those sites is hard work
it'd be easier to just contribute to Documentation.
yea it probably is. You also get a silver badge and a chance for swag
I don't want documentation swag
I want a new ducky with the CR logo still on
2
@Pimgd I see your name everywhere on the main page
@Pimgd @Dex'ter
basically, I retagged a bunch of stuff... pretty funny that two people are spotting it so far; usually it goes by unnoticed!
@Pimgd Justice never sleeps :p
15:46
0
Q: Singly Linked List implementation in Python

CodeMonkeyI'm new to Python and thus learning it by implementing a set of commonly used data structures. Here's my implementation of a LinkedList. First the Node class. class Node: def __init__(self, value = None, next = None): self.value = value; self.next = next; Here's the Linke...

0
Q: Postponed Prime Sieve in Swift

Martin RMotivated by Unbounded Sieve of Eratosthenes in Swift, I looked out for other "infinite prime generators", i.e. functions which produce the list of prime numbers in increasing order and do not have an a-priori upper limit (such as the standard implementation of the Sieve of Eratosthenes). Repeate...

16:02
This might be a good question for Code Reviewnull 16 secs ago
@Pimgd Shiny, that's more than the network thingy tells me.
@Pimgd Mr. Duckrubber.
16:18
@dbmitch - I've simplified the code for this. I have a second sub to take the array, and put in .txt/.xlsx. If you click the "CodeReview" link I put in there, there's another method I tried as well, that includes the .xlsx info. — BruceWayne 12 secs ago
I'm doing something stupid. I shouldn't do this on a Friday.
0
Q: Releasing references in a proper way with server connection library

FlloI work on a custom library (Co.line) to do HTTP requests in REST. I tried to think of reducing the memory usage by cancelling the thread background and destroying all references. It uses a Context reference to retrieve the server response in main thread from a callback. I used this lib in one of...

hey @Quill do I remember correctly that you wanted to post about site health?
Interesting I hadn't heard of Code Review before. Though I did see meta.codereview.stackexchange.com/questions/5777/… "Please do not vote to close with a custom reason that "it belongs on Code Review". " — kbeal2k 50 secs ago
First version of SVG logo complete
I'm surprised that inkscape doesn't have edge constraints like CAD software does
That would've made this sooooo much easier to make
Zak
Zak
@Duga Bad. Bad. RBA, probably incoming.
If you haven't included the code that hangs, then your question is incomplete and tough to help you with. We aren't going to go back and forth between Code Review and here — dbmitch 7 secs ago
@syb0rg The rounding seem inconsistent.
It may be visual, but it appears like the top left is thicker than the rest.
Yes, another problem with Inkscape... rounding edges
16:40
Why did these edits not get rolled back?
I doubt it even works.
in The h Bar, 15 secs ago, by syb0rg
::populates starwall, runs away::
@Mast Duga should've only told us about the last one..
@Vogel612 Yup, but after the last edit, I'd expect a revert back to rev 4.
Opinions?
and cleanup of the edit scars.
if not rollback to rev 2
I'm thinking rollback to R2
I've done it and made a comment, fix as you see fit
in The h Bar, 5 mins ago, by 0celo7
what are these stupid stars
lol
16:47
Invasion of the stars.
@Mast Hm, yes I think you are right... ugh
0
Q: K&R 2-7 - Invert a bitfield from a number

Lúcio CardosoThis is my solution to the Exercise 2-7 of K&R C book. The assignment is: Write a function invert(x,p,n) that returns x with the n bits that begin at position p inverted (i.e., 1 changed into 0 and vice versa), leaving the others unchanged. Note: It's assumed that the rigthmost bit of a num...

@syb0rg I'll recruit my wife, send you a shinier version tomorrow.
The base idea is very good, so it's going to be okay.
I do like the idea, but it's a pain to fix with Inkscape
I'm just too used to engineering/CAD tools
Zak
Zak
Soon...
16:54
@syb0rg So why not draw it in CAD tools?
SolidWorks can do some weird things with characters.
@Zak About time we got another Electorate holder :-)
Zak
Zak
But now I'm confused about its' measuring period. I'm at 500 votes this year, and 1,350 all time, so where does it get 580 from?
question votes
Zak
Zak
@Vogel612 duh, of course. I should actually take time to parse the text rather than just read it ^^

« first day (1182 days earlier)      last day (3133 days later) »