« first day (1096 days earlier)      last day (3218 days later) » 
00:00 - 17:0017:00 - 23:00

17:10
possible answer invalidation by Kim Gysen on question by Kim Gysen: codereview.stackexchange.com/posts/127440/revisions
@Duga Handled, and thanks.
Maybe we should have a review system for everything @Duga posts...
@SimonForsberg handle replies to answer invalidation posts, and track stats on how much are handled, deemed "ok" vs "actual invalidation", and publish stats at reload :)
@Mat'sMug Yeah, considering something like that...
0
Q: Md5 has that starts like digits of pi

guestI tried to make a program to find a string whose MD5-hash starts like the digits of pi, where dot is omitted. Is there a faster way to do it than this: import hashlib import random import string n = 1 while True: word = ''.join(random.choice(string.ascii_lowercase) for _ in range(20)) if...

http://www.commitstrip.com/en/2016/05/04/not-everyone-is-made-for-front-end-design/
CommitStrip
Not everyone is made for Front End Design
CommitStrip
1462382243
17:22
@CommitStrip pixel pushing is evil
@DanLyons So is serving the dark side.
@CaptainObvious I'm really not sure if that is considered "working" or not.
the rebels are the bad guys
@CommitStrip Wow, there's a typo in developpment, that's kind of sloppy
heh, I wish I could say I've never done this before
I just spent 45 minutes investigating a bug fix to see why it didn't work. Root cause: I didn't actually deploy the fix.
2
17:27
lol
@DanPantry @Marc-Andre I think it's on-topic. There is a difference between "not converging" and "converging slowly" though...
@Quill has @rolfl made a Neural Network?
@skiwi I think they're French
doesn't excuse it, but could explain it
@DanLyons We all did.
45 minutes is an optimistic case though :P
@Mat'sMug Could be Canadian, they publish in at least French and English.
17:34
0
Q: SQL inserts and Table creation Issues

NonCreature0714I'm creating a small database for an airline. I don' think my syntax is off, but something is going wrong in table creations/test data insertion. I'm using the Oracle DBMS and SQL syntax. I'm not looking for anyone to writecode for me, but I'm very constrained for time and need clear indications ...

could be
With IBM releasing their Quantum powerhouse to the general public, it could be a matter of years before RSA goes down. Hard.
Meanwhile I'm having trouble getting a basic understanding of algorithmic notations...
17:55
@Mast Yeah, we have tons.
0
Q: Storing hierarchical data into a data structure

MikeyWith the following data in a table, +----+-----------+-----------+---------+ | id | name | parent_id | prev_id | +----+-----------+-----------+---------+ | 1 | Section 1 | NULL | NULL | | 2 | Item 1.1 | 1 | NULL | | 3 | Item 1.2 | 1 | 2 | | 4 | Item 1....

How did that get starred?
4
I could use a good primer if anyone knows one.
Everything here has a chance to be starred
2
@Mast Eh, at what part ar eyou stuck/need help?
0
Q: Insert string in a file

TonyI made this code which inserts a string at the specified position void insertar(FILE * archivo, unsigned int pos, const char *nueva_cadena, unsigned int longitud_cadena) {    char *buffer = malloc(longitud_cadena);      fseek(archivo, pos, SEEK_CUR);    fread((void *)buffer, sizeof(char), lo...

18:11
@skiwi Well, I was reading a book about evolutionary computing yesterday. Not knowing the notation hasn't been too much of a problem, but I don't know half the lingo either.
That's a bit too vague for me :/
Crossover points, cutting parents into segments, it's all gibberish to me.
Cutting parents into segments in an evolutionary book, that's interesting
But I've had Algorithms classes and don't know those definitions either, so you're looking at something else than just notations I think
lol
0
A: Why would a type be coupled with its builder?

DeadMGNo, they're completely wrong and you're absolutely right. That builder model is just silly. It's none of the Person's business where the constructor arguments come from. The builder is just a convenience for users and nothing more.

18:15
@Mast Readable to me, but abuses some braincells
@skiwi My braincells are having trouble parsing that.
Is there an operator overview somewhere?
What's the biggest issue? M \ge max{q(p) | p \in P}?
@Mat'sMug If that would've been the start of something bigger, it definitely would've gotten my upvote. But it looks unfinished as it stands.
IKR
Thanks... I'm sure this answer would collect more votes if it expanded a bit more, it looks like an unfinished answer =) — Mat's Mug 9 secs ago
3 mins ago, by skiwi
What's the biggest issue? M \ge max{q(p) | p \in P}?
18:23
@skiwi The biggest issue is those blocks of the whole thing together. They make me lose my grip.
I can do slippery, but I can't walk on an ocean.
You've really got to read it a few times
Awesome. If youre interested in the array configuration, here's where I asked code review about a better loop procedure. codereview.stackexchange.com/questions/121434/…Doug Coats just now
M ≥ max { q(p) | p ∈ P }
What does that even mean?
That's quite simple actually... if you knwo the notation
M has to be great or equal than the expression on the right
9 mins ago, by Mast
Is there an operator overview somewhere?
18:27
Which is the maximum of the function q applied on p for all p in P
That's easy.
So | isn't a OR operator here?
They just write it in a shorter form to make it easier
@Mast Nope
For some values of easier.
I don't remember where I learned these structures, not in algorithms class I believe though
I think genetic algorithms would be great for simulating mesh networks.
@skiwi So, you don't have an overview? ^^
@Mat'sMug I got Pundit on Programmers today, but that comment didn't get to +5...
18:32
@Mast Not really, I just happen to know these things :/
0
Q: Follow-up zp-Tree to represent Trees as nestes arrays

Kim GysenThis is a follow-up on the post: zp-Tree library to represent trees as nested arrays I have made modifications based on the feedback received on the previous post, hence I request another review on the modified code if ok. I created a jsfiddle here: https://jsfiddle.net/yc6z3v13/ /** * zp-T...

I think I've been deciding longer on whether I want to buy this game than the time it would've cost me to make the money needed to buy this game
There is no actual question here, just a statement of requirements and dumps of a bunch of hideously formatted code. If you want a review of your working code, use codereview.stackexchange.com. If you want someone to finish your work, discuss your work and have extended discussions about what to do next, you are at the wrong place. — Jarrod Roberson 11 secs ago
@skiwi What game?
@Mast The Division
18:35
I've heard it's good. That's about as far as I got on that.
Much like algorithms, really...
I wonder how one could make a game about programming they way they've made games about hacking...
Oh man, if I could just buy my way through Algorithms and end up with the knowledge at the end :P
@WaymanBellIII
@skiwi From what I've heard it's decent, but it's not too great unless you're playing with friends.
I guess I can get my money's worth while playing with friends and then have it rot in my games library play some solo later
2
18:37
Where to download friends?
> Pay only $9.99 (and an additional $0.99 for each new friend) to add friends to your experience.
> For every friend you recruit you will receive a new friend.
I never thought I would say this, but I should watch more GIFs.
3
StackOverflow is a Question & Answer site. If your code still needs some work, please update your question (use the 'edit' link) and include your best effort and a description of exactly what went wrong, we can definitely help (and some of the downvotes will likely be reversed). If the code you wrote works perfectly fine as is and you'd like to see if it can be improved for performance, readability, etc. feel free to post that on our sister site, codereview. — p.s.w.g 56 secs ago
That, my fellow comrades, is mergesort for dummies.
No text necessary, instant recognition of how it works.
That is how one should explain algorithms.
18:41
I wish my exams came with gifs
2
I remember seeing a computerphile video a while ago where they explained different sorting algorithms with nice colorful graphs.
0
Q: 2D Grid search in larger 2D Grid

willredington315The goal is to return a boolean as to whether the 2D search area exists in the larget 2D grid. My logic is as follows: Find the first occurance in the grid that equals the target grid Find all connecting cells that exist and are in target grid If the test grid doesn't have the current cell a...

BASIC is awesome.
I don't see why, as a dev, it's harder to edit a .clj text file then it would be a .txt one. If you find it easier, that's fine, but this is not an idiomatic way of writing Clojure, and as an engineer, it would not pass my code review unless you could justify the additional cost of why you're reading your exception msg from a text file. Not breaking the 80 line count would not cut it. — Didier A. 38 secs ago
18:50
@Mast I liked the videos involving dancers to depict various sorting algorithms
as funny and troubling as informative
@Mast Alright, I'll graph those when I get home and post them up.
Oooh, graphs.
Just plot them in BASIC and dump a screenshot every day.
So... higher coupling, lower cohesion => happy ending? hmm... I see the point about the builder "extending the constructor", but to bring up another example, I fail to see what String is doing with a constructor overload taking a StringBuilder parameter (although it's debatable whether a StringBuilder is a builder, but that's another story). — Mat's Mug 6 mins ago
I'll make three graphs: one for those fields, one for the derivative of each, and one for the second derivative of each.
Puzzling.SE got their design!
18:56
Yea, they got a fancy logo.
bwahahahahaha
@Mat'sMug To be clear, I don't really have a strong feeling about this either way. I don't tend to use the builder pattern because I don't really create classes that have lots of state input. I would generally decompose such a class for reasons you allude to elsewhere. I'm just saying is that if you can show how this approach leads to a problem, it won't matter if God came down and handed that builder pattern to Moses on a stone tablet. You 'win'. On the other hand if you can't... — JimmyJames 1 min ago
@skiwi Found out what they meant with slicing parents:
I think...
19:18
I've been going about this all wrong. Those operators aren't algorithmic, they are mathematical.
0
Q: C function for copying array into matrix

Programmer 400I want a matrix that can grow dynamically and build up a structure in RAM as input arrives from standard input och terminal (shell). First I tried with a matrix like A[nrows][ncols] but I changed to the ** A[n] and I want to refactor so that there are fewer constants and that malloc will be safe...

0
Q: First C# program (Snake Game): Did I overcomplicate things?

WagaccaI've just started out using C#. I've used Scratch (drag and drop programming for kids) for quite some time. Since Scratch didn't have classes and methods i have a feeling this code could be a lot more streamlined, neat, efficient, more read-able, shorter and in general just better. Console Snake ...

Now all those odd papers make sense...
| is a collection and is an element.
Arrows are implications.
On what system is it failing with what configuration? (i.e.) What OS, compiler, options, etc? Also, put it all in a single file and post that here. I've code reviewed it [and tested] and it seems fine. — Craig Estey 1 min ago
possible answer invalidation by Wagacca on question by Wagacca: codereview.stackexchange.com/posts/127515/revisions
@Duga Nope. Also, the answer on that is horrible.
this code should be in code review — Mostafizur Rahman 35 secs ago
I'm voting to close this question belongs to code review forum. — Valentin 53 secs ago
19:37
@Duga No.
0
Q: C forward list with remove

PatrykCan you please point out any problems with this C forward list with remove node functionality? I believe this can be way simpler ( removeNode function ) but I somehow cannot grasp it #include <stdlib.h> #include <stdio.h> #include <assert.h> struct node { int val; struct node* next; }; typ...

19:56
0
Q: What kind of members should be used in a GetHashCode() implementation

Jeroen VannevelWe're building some Roslyn analyzers concerning GetHashCode(), including an analyzer that implements it for you in a given class. While researching the subject we've found that there are many considerations to take into account, mainly on what kind of members should be avoided in a GetHashCode()...

want more eyes on this
I never knew until now how hard it is to figure out what kind of members should be in a GetHashCode() implementation
@JeroenVannevel So, allow all mutables?
Mutable members are not a joke, @Mast
Naruto answer; accepted non-selfie answer with 0 score: Forum project using OOP PHP
Ripe zombie; open question with answers, at least one answer having score 0, no answer having score > 0: Archiving an SQL table of sessions and statistics
@JeroenVannevel Your point?
I thought you were joking
20:04
Nope.
Mutables are specifically excluded per the guideline
That doesn't leave you with much to hash.
if you use a mutable member in your GetHashCode(), put the object in a hashtable (like Dictionary) and mutate the object, you will never find it again in there
That's a really hard issue to debug
I know. Hence the question to verify if I didn't overlook anything
20:06
So disallow the entire function.
and to see if there are any other ideas on it
disallow GetHashCode()? What do you mean?
Well, if GetHashCode only works on mutables and mutables aren't allowed, the function can't be allowed, right?
most reference types are fine with the default reference equality
@Mast I can't "forbid" GetHashCode(). It's used by the default collections
It's up to me to provide a solid implementation
solid in the sense that it will provide a base implementation without any of these hidden problems
return base.GetHashCode(); // safe as can be hahahaha
20:13
I don't get it. Ah well.
0
Q: Can we do away with “someone else's code” wording?

Joe WallisThe other day we got the question Python - Print the average of a list which is a value in a dictionary [on hold]. When I came across this question it was being closed for a custom close reason, I can't find it, but the comment they made is: I'm voting to close this question as off-topic beca...

This question would be more appropriate on Code Review. It's not necessarily off-topic here, but that site is specifically intended to handle this kind of question. if you open the same question there, make sure you delete this one so it's not posted on two Stack Exchange sites simultaneously. — skrrgwasme just now
20:30
In .NET, certain collections are based on a `HashTable`. One of these collections is `Dictionary<K, V>` that maps a certain key (`K`) to a value (`V`).
The way this is done is by providing a certain amount of "buckets" internally: literally a bunch of smaller collections inside the dictionary.
Every object that is added to the dictionary is put inside one of these buckets. Which bucket it is exactly is decided with the `GetHashCode()` method that is present on every class and struct (inherited from `Object` or `ValueType`).
Now, that's some background on why distinct hashcodes are important. Now we'll look at why it's important to have these hashcodes remain constant. What if your hashcode is based on your firstname, lastname and food preference?
Let's assume for simplicity that your names never change. Let's create an object "Johnny McFlamboyant" who really likes lasagna and put him in our dictionary. A hashcode is calculated, johnny is put into the corresponding bucket and we're done. However Johnny is a little punk and decides he now likes pizza more. I was still holding on to the johnny object so I change that object's FoodPreference property to Pizza.
This all works fine and Johnny is now pizza hut's personal mascot. If I now try to retrieve the object I just put in by using my key (the johnny object) it won't find it anymore. When I do that lookup, the underlying hashtable will look at my object, calculate the hashcode and retrieve the value that corresponds to "Johnny McFlamboyant Pizza" instead of "Johnny McFlamboyant Lasagna" which is in the table already.
Suddenly, without even discarding of the object that started in the first place, my lookup fails.
@Mast
and not only your lookup fails, you're stuck with an item in your dictionary that you can't retrieve easily. and if these are VBComponent objects and each has a ParserState then you've got that item stuck in ParserState.Pending state, and that breaks your EvaluateParserState implementation.. true story involving mutating hashcodes with COM interop objects.
Jan 18 at 11:34, by skiwi
@rolfl I've heard the term trampolining once before, I need to read more about that
20:53
So, if I understand it right, the code actually works correcctly? And what you want is suggestions to improve it? Then it is more appropriate for our sister site Code Review. — S.L. Barth 37 secs ago
21:09
It seems to me that you posted your question on the wrong site. Code Review is where they handle existing / working code and do their best to improve it in terms of speed, security, sustainability, and longevity. Give it a try. They're good! — Ralph 29 secs ago
3
@NoodleOfDeath I would recommend taking a look at Code Review, although note that in order for a question to be on-topic there, you should be presenting working code. — originaluser2 20 secs ago
0
Q: Cross browser JavaScript implementation of xhr

JustinI wrote a small, cross browser compliant implementation of client JavaScript xhr requests that closely follows jQuery $ajax() standards. The goal is to keep the function very small in size, yet cover most common xhr sceneriors. I'd like code review for performance, general best practice, and the...

1 message moved from Discuss Close Reasons
I didn't want to shut down discussion, but I figured that moving the discussion to the appropriate room would be tidier.
21:31
0
Q: How can I make this Python function run faster?

Artem KorolFunction findMinimal() receives a tuple from a list which contains 171 tuples, each of them go in to the function one by one and for each tuple it searches the best pair via "minimalTscore" out of those that match by "industry" (approx. 20 names, for each one). How can I make the function to run ...

0
Q: Implementation of Quicksort

BlackMI have implemented Quicksort in Java: import java.io.*; import java.util.*; public class QuickSort{ static void quickSort(int[] numbers, int startPoint, int endPoint) { int pivot = numbers[startPoint]; int left = startPoint+1; int right = endPoint; int currentPoint = startPoin...

21:41
0
Q: WebRTC little confusion

Vito LipariI have some confusion about RTCPeerConnection, Signaling and STUN servers. The stun server make signaling? If the STUN servers doesn't make signaling, what are the STUN servers goal?

possible answer invalidation by Dr. House on question by Dr. House: codereview.stackexchange.com/posts/127173/revisions
@Duga Every House MD episode ever
4
0
Q: When values are pasted into a bigger range, the values should be repeated as needed to fill the range

sharkpanicI am currently working on a project and I just wrote a piece of it that requires a lot of array manipulation. Given a text input I want to expand it to fill the number of rows and columns I have. I worked out a solution but I am concerned that I am creating too many arrays in my solution. I am...

22:08
I've commented with my concerns with Robert's and Simon's proposals.
Any remaining issues with this slate of close reasons?
5
10
A: How should we revise the standard off-topic reasons, if we can have up to five?

200_success Code Review is a community where programmers peer-review your working code to address issues such as security, maintainability, and performance. Questions about code that has not yet been written, code that does not work as intended, or code that the author does not understand are off-topic, as...

22:46
0
Q: creating an istream peeker

BarryI want an istream that you can safely peek arbitrarily many characters from. This works as far as I can tell, but I am unsure if this is really "the right way" to do it since the iostream library is pretty cryptic to me. All comments welcome: class peekbuf : public std::streambuf { std::stre...

00:00 - 17:0017:00 - 23:00

« first day (1096 days earlier)      last day (3218 days later) »