« first day (1009 days earlier)      last day (3008 days later) » 
00:00 - 23:0023:00 - 00:00

12:00 AM
RELOAD! There are 1804 unanswered questions (94.2111% answered)
 
That is some interesting reading @JeroenVannevel
 
I got it from here, which is also worth a read: mattwarren.github.io/2016/02/04/…
 
Duly noted! Thanks!
 
I was already aware of how the GC works in general but this also puts the actual C++ code that does that next to it
it helps clarifying things
 
Oh. Nice.
 
12:03 AM
I cannot tell you how much I love chrome.google.com/webstore/detail/tab-snooze/…
Every day I get some of my older snoozed tabs that pop up and I can decide whether to read them or not
this is how I actually get that done
 
@JeroenVannevel that thing needs too many permissions and I really really really don't like the UI
 
You don't?
I thought the UI is incredibly good from a UX standpoint
you literally just click the icon and select when you want it to pop up again
You don't have to open the links yourself -- they automatically open up in a tab when it's time
together with a 'ping' sound
I often forget what I had snoozed until they suddenly show up
 
Zak
12:39 AM
@JeroenVannevel @skiwi it's perfect for you :p
 
12:55 AM
0
Q: Creating Numeric Battle System Backend in Java

Datt ManielsI've been trying to debug this simple battle system I've been attempting to achieve. I'm at a severely basic level and have made a debugging main file to figure out the source of the problem. The main battle functions I've created: package great; import great.Player; import java.util.Scanner; p...

 
@csodium: If it's failing test cases then this means the code is not working (it obviously fails to solve the problem correctly). So please correct you algorithm - after that you can post it for review on codereview. — ChrisWue 21 secs ago
 
1:15 AM
0
Q: Pseudo-Code: Python Editing live Feeds to derive direction

CENTURIONI am wondering if anyone can help me pseudo-code this one out. Issue: I have a live feed coming in coming in from a local host, port 3333. That data is feed is being updated with incoming x & y location, tracked object number, motion and acceleration info. To derive direction, I need to know...

 
 
2 hours later…
3:24 AM
0
Q: Armstrong Number Validator

Jae BradleyPurpose Validate if a number is an Armstrong Number. An Armstrong Number is a number such that the sum of the cubes of its digits is equal to the number itself. For example, 371 is an Armstrong number since 3 ** 3 + 7 ** 3 + 1 ** 3 = 371. Strategy Calculate the remainder and quotient of...

 
3:42 AM
0
Q: Groundwork for a "visual scripting interface"

Gaston GilbertI've begun work on a program that allows the user, through use of a drag-and-drop GUI, to write basic "scripts" that can then be executed. It is heavily inspired by Unreal Engine 4's blueprints. As I have never had my code peer reviewed before, I thought I'd use this project as a way to improve ...

 
4:05 AM
0
Q: Bookshelf with Sorting, Categories and File I/O

BrainFRZI've been working on a project originally for school regarding object-oriented design, where I was supposed to write a class for a book and a bookshelf, and then have a driver class to add a couple books and print out their details. I originally started this project a while ago, adding and changi...

 
4:35 AM
0
Q: Is this a good Object Oriented Code?

Rutvik D MehtaIs there any object oriented way or design pattern I can use to make this code better. How can I avoid casting in bellow code? What if I add new Object like WaterTank how will it interact with Fitting? Here are my code classes Run.java package main; import fittings.Fitting; import fittings.Ta...

0
Q: Sherlock is going against the Beast with PowerShell

MattI ran into this challenge a couple of times today and thought I could tackle it with PowerShell. I refused to look at other peoples approaches to this hoping to complete it on my own. I'm sure the general idea is the same in either case. I have included more comments than I would normally to help...

 
5:28 AM
6 Captain posts in a row. pretty slow day, it seems
 
5:55 AM
@Matt I decided to help you out some. Take a crack at that.
Good night.
 
night
 
0
Q: Power-Guessing The Number

Hosch250I decided to help @Matt out a bit and ask a PowerShell question. This is a simple guess-the-number game learning how to use functions with and without parameters, and use the input and output functions. All comments are welcome. Function GetNumber([int]$min, [int]$max) { Return Get-Random ...

 
6:18 AM
0
Q: Simple java calculator using JOptionPane

TempFirstly- thank you in advance for all the help. I am very new at java programming and I apologize if the answer to my question is incredibly simple. I am trying to create a simple java calculator that uses JOptionPane, while loops and the logical operators || and &&. So far I am able to compile...

 
nooo, I lost my 367 day consecutive visit streak
 
powershell is cool
 
7:01 AM
0
Q: Car loan calculator app not working right

ssgjbroylesI'm very new to Java and to Android programming. I'm working on a car loan calculator that works for the most part, put I'm not getting results after I click on the "calculate" button. Before I hit calculate: Total of Loan: $10,000.00 Monthly Payment:NaN Total Interest: 10% I don't really mind...

 
 
2 hours later…
8:45 AM
0
Q: Terminal ESC Sequence Decoder

MercyfulFigured i'd share some code and get some feedback. The goal of this code is to read-in a stream of terminal ESC sequecnes, and break them down and fill a vector of parameterized sequences for processing later on. For escample ESC[5C would be filled in the vector as: Vector[0] = C Vect...

 
9:00 AM
Naruto answer; accepted non-selfie answer with 0 score: Finding the object and the URL associated with a notification
Ripe zombie; open question with answers, at least one answer having score 0, no answer having score > 0: Using Rails concerns for validation in models
 
0
Q: Scrape the url's of the pdf files on a given page using python libraries

deepesh00How do i get the urls of all the pdf files given on a specific page using python libraries like beautifulSoup and download all of them one by one?

 
9:22 AM
0
Q: Using JavaScript's Array.splice with assigning the replacements item as an array

bo256I've got to delete / replace elements in an array. For accomplishing these task one usually uses Array.splice(). Problem: Array.splice() expects the replacement items as a comma separated list. But I got the values as an array. I've made this helper function which makes it possible to use spli...

 
10:13 AM
0
Q: Python random variable not working

Keith AmosIm creating a text based game and I want to implement a fallout 4 'wasteland' system. I figured that a good way to keep everything random was to make a random.randint(1,10) function and some if statements for every number that comes out. The problem is that when I randomise the variable, the numb...

0
Q: Simple stack structure in C

Isty001I just started to learn C, and for practicing, I tried to implement a simple stack data structure, and I want to know if I'm making any mistakes, or how could I improve it: My stack.h: #ifndef STACK_H #define STACK_H #define STACK_MAX_SIZE 125 typedef struct { int max_size; int items[...

0
Q: Saving User Settings in Univeral App for Windows 10

IlluminatiI am a self-taught programmer, so please be gently. Please give as much feedback as possible for my code. I want to make sure I am doing things the right way and efficient way. What is the proper directory to save this info? What file type and what format? How do I load these settings when the...

 
0
Q: Simple text boxes xamarin app

EminemI've just started learning Xamarin. I've create an app that has 4 text boxes. When the app starts, the first text box starts looping from min range to max range until the user presses a button. Than the first text box stops, the second one starts etc. My main issue is the threading part. I'm pr...

 
1
Q: Given a 2D array of digits, try to find the occurrence of a given 2D pattern of digits

c fun funMy algorithm is quite simple. I simply iterate over the entire map arr and if I find the start of the combination I need to find, I begin exploring. My combination data structure is simply the combination I need to find, column at a time. If each column in arr matches, I return True. If at any ...

0
Q: Independent interpolations, or object linked?

XriukI have a class that I use to render GUI elements on the screen, this class has a tree structure (with children, parent, and siblings). I created an additional class which allows me to interpolate some values of a GUI element (alpha, and rotation for now), each instance of the class is linked to o...

 
Hi @Eminem
@Eminem What is it that you want to say with posting that question here?
 
10:57 AM
@SimonForsberg Idk. I guess I'm trying to get attention to that question :)
 
@Eminem You might want to read this, there are some tips in there that could be useful for your question:
12
A: Checklist for how to write a good Code Review question

Simon ForsbergSimon's Guide for posting a good question There are a lot of questions that appear on Code Review, and all questions are fighting for reviewer attention. This is a non-exhaustive list of items that I am looking for in a Code Review question when determining whether or not I should review it and ...

In particular: Screenshot.
 
@SimonForsberg I dont see how a screen shot of my gui has anythiing to do with this piece of code.
 
@Eminem It is a GUI, it will make your question more interesting, whatever your exact concern with the code is.
 
possible answer invalidation by bo256 on question by bo256: codereview.stackexchange.com/posts/119167/revisions
 
And you do know that generally on Code Review, you might end up with any particular advice, even some advice that you're not specifically asking about?
 
11:07 AM
I am aware of that. The problem is that this is not the full application, and there are many pieces of code which i will not post in here, due to length issues. Again, my main concern as of the moment, is to validate my use of threads or the unuse async/await/task principles.
 
11:19 AM
0
Q: Command Prompt TicTacToe in C#

Rezo MegrelidzeI wrote a basic command prompt tic tac toe Game. I want to know what can be improved in terms of modeling, what mistakes i made (if any). Here's the code: void Main() { TicTacToeBoard board = new TicTacToeBoard(); while(!board.GameOver()) { var i = int.Parse(Console.ReadLin...

 
11:49 AM
I guess this is going to be hard to debug since we will have to derive the rules from the code. You might get help faster if you ask for a code review at codereview.stackexchange.com but it may not be for free. — Roland 15 secs ago
 
12:13 PM
@Roland I am having an issue where it's not counting people that are on shift correctly. indicates that the question is off-topic for Code Review. Please read A Guide to Code Review for Stack Overflow usersSimon Forsberg 1 min ago
 
monking
 
12:24 PM
0
Q: Is this enough to go interpreting language in text?

The Pro HandsI'm making an Lua interpreter in JavaScript ! My interpreting method has as goal return an array with the lines from user script or return any syntax error case found. It should interpret script inside an string, step-by-step! It's not done yet, but I did a base and rules for each statement. Th...

 
Monking
 
Have you tried it out? What is the problem? We do not do code reviews. — TomTom 42 secs ago
 
so I can't decide whether this is code unwritten yet
0
Q: Is this enough to go interpreting language in text?

The Pro HandsI'm making an Lua interpreter in JavaScript! My interpreting method has as goal return an array with the lines from user script or return any syntax error case found. It should interpret script inside an string, step-by-step! It's not done yet, but I did a base and rules for each statement. The...

It works as far as he's implemented a statement check, but for what he describes, it's nowhere near a complete solution
 
@Quill I gave it a quick glimpse, it's one dictionary, that's not so much code
 
12:42 PM
If you're just looking for a code review, that's off-topic for Stack Overflow. There is a Code Review Stack Exchange site you might try. Though actually showing the code you want reviewed will be helpful there. (Or, if it's more of an architectural review, actually showing information about the architecture would be helpful.) — David 11 secs ago
@David On Code Review we're not satisfied with showing information about the architecture, we'll need the code. (It's called Code Review for a reason). Judging from this start of the question though, it's nowhere near Code Review material. — Simon Forsberg 33 secs ago
@SimonForsberg: Agreed. The subject is definitely closer to Code Review, but the question needs to be improved first. (Even if it's improved here, it's still off-topic here.) — David 27 secs ago
 
Monking
 
I don't want a code review for something it's not coded yet. I need advice to build the new project structure. In the old one was with strong coupling and I want to have a new weak coupling structure with unit tests. — www.innovacall.com 31 secs ago
 
@Quill Definitely not written
> It's not done yet,
 
0
Q: Is this a good way to test a controller method that returns JSON?

MohamadI'm building a JSON API. I'm writing my controller tests so that they compare the response body to actual JSON I'm generating in my tests using ActiveRecord. I wrote two helper methods that make the process easier. The first simply parses the actual response body and returns it. def json_respons...

 
chrome is still borked
 
12:59 PM
@Quill Hammered.
 
For Multiline string: you missed your terminator again. Have a look at here-strings. You need to have "@ to terminate the string and it must exist on its own line. Good catch on the types. That is a common gotcha in PS — Matt 1 min ago
I think I like PowerShell
@Quill Yeah, but... in the title says what it does, not? — The Pro Hands 28 secs ago
 
1:27 PM
0
Q: printing the alternating character in half of string

Ashwani Thakurthe below code is showing runtime error on compilation. #include<iostream> using namespace std; int main() { int t,i; string batman; cin>>t; while(t--){ getline(cin,batman); for(i=0;i<batman.length()/2;i=i+2){ cout<<batman[i]; } cout<<endl; } return 0; }

 
> runtime error on compilation
that's a new one.
 
1:55 PM
On this code: Maybe I better ask on SO
0
Q: Are guards to check if a method has been called optimized by Java?

skiwiConsider the following code: public class BasicBuildOrder { private List<GameObject> gameObjects = new ArrayList<>(); private List<GameObject> savedState; public void saveState() { savedState = new ArrayList<>(gameObjects); } public void resetToSavedState() { ...

Makes sense? ^^
Lol, someone downvoted that within 1 minute already... Oh well, it's SO after all
And it's gone already, maybe someone misclicked lol
 
hmm that's weird
 
@skiwi That downvote was from me initially because I didn't find the question very interesting, and I expect the answer to be "No".
@Quill Are you calling me weird?
 
sure, why not
 
@SimonForsberg In that case I have to retract my accusations against SO I think?
 
> is there a pattern available for this methodA-called-before-methodB relation?
 
2:07 PM
I'm not so sure if the answer is no
 
feels more like a programmers.se question, but scope on programmers is weird
@skiwi it's been out for a few minutes, you might have a reason to accuse SO in a few more
 
I know that bound-checks can be optimized at some point
 
What you currently have in your code is called temporal coupling, and AFAIK the best pattern to avoid that is to use two different objects: For example SavedBuildOrder and UnsavedBuildOrder
 
I'm not sure how that mixed with expecting some performance of the code
 
Your question smells of premature optimization. Of all your code, your if (savedState == null) statement will be the least of your worries.
 
2:10 PM
It smells, can't deny that
But I wouldn't be writing that check if it wasn't for best practices, you don't want an NPE at some later point
 
@SimonForsberg also no, I was commenting on how I had the post loaded, and didn't notice any downvotes at all (the answer to your comment was a joke, please don't be offended)
 
@Quill I'm not offended.
@skiwi Then why are you wondering about it being optimized away or not?
 
@SimonForsberg Because I'm interested in knowing the answer
 
In fact, I'm bringing back the downvote. Sorry.
 
2:18 PM
Also, you might want to consider returning the list from the save method and passing it to the restore method. And your method resetToSavedState would be better named as restoreState.
 
@SimonForsberg Right, agreed on the latter, on the former, not so much
Basically my use case here is backtracking, but instead of undoing the change, I want the data structure to be able to handle that
 
0
Q: Chain of promises

David MulderOften I end up with var askName = () => { return new Promise((resolve, reject) => { this.waitForInput('Name:').then(name => { this.ask('Are there more players?', ['Yes', 'No']).then(answer => { if(answer === 'yes') { askName().then(res...

 
@CaptainObvious Weird moment when you recognize the profile picture, as he's a member of some Dutch tech site :P
 
I think the question may be off-topic
I'm certain the code works, but I think it's more of a pattern question
 
@Quill And how is that off-topic??
 
2:23 PM
well it's hypothetical, I suppose
it may as well be foo().then(() => bar.then()
 
But it's not.
This is exactly how you are supposed to make hypothetical questions non-hypothetical.
4
 
so they make hypothetical questions non hypothetical by adding code that we can't run anyway because it's all part of their unlinked solution
 
There's no requirement that all CR questions should be runnable out of the box.
2
 
I should have read wiki.openjdk.java.net/display/HotSpot/PerformanceTechniques first, but only found it after I already asked
 
out of the box, and integrated code are very different
@skiwi those disassemblers always look confusing
 
2:30 PM
My recent Linq expressions question can't run, and I'm not hosting the source anywhere either..
 
@SimonForsberg fixed, thanks
didn't think that one through completely
 
so, this is unacceptable:
var num = 44;
var f = new Foo(num);
if (f.lorem == Foo.defaultLorem){
    return new Bar(f);
} else {
    makeDifferentFoo(num);
    return false;
}
 
0
Q: Message bus in C#

Bogdan YaremaI wrote a MessageBus class whose only purpose is to deliver messages from object to object without direct link between them. I encountered a problem of some code parts being wrote twice caused by requirement for same methods with and without generic types. It is bothering me so please check my c...

0
Q: React Weekly Calendar

macurieI'm trying to create a weekly calendar with React. Code: jsfiddle How do I get the hours to the left aligned with the lines? How can I improve the code? (js and inline CSS) How can I improve the layout? Any suggestions and improvement are welcome.

 
but this is fine:
var port = 44;
var WS = new WebServer(port);
if (WS.port == Foo.ftpPort){
    return new FTPWS(WS);
} else {
    makeSTMPWS(port);
    return false;
}
even though they both call internal, unknown functions, both have the same pitfalls and issues, one is just named differently
 
yeap
sounds about right
 
2:37 PM
@CaptainObvious off-topic, code is not included
 
Have you ever gotten that "oh god, what have I just done?" Feeling? Yeah. Volunteer to work on a dotnet/corefx issue. You'll pretty much instantaneously get it.
 
lol
 
this was flagged as broken code, with 8 upvotes. thoughts?
1
A: Power-Guessing The Number

MattNeeds more variables I see plenty of integer constants. They define the upper and lower bounds of the game. Let turn those into variables and define them. Makes the game easier to make changes. Function PlayGame([int]$min, [int]$max, [int]$NumberOfGuesses) { # Hilarity ensues } Since the...

 
@Quill I think OP didn't know it was broken, thus on topic.
 
@Quill pretty much yes
 
2:52 PM
@RubberDuck Cross Platform IO is a royal pain. You might be interested in a java-based solution to the problem
 
it's probably a potato CPU if he's worried about such things. — bayou.io 8 mins ago
^^ I stand by my downvote to your question.
 
Does a calendar question deserve a tag?
 
@SimonForsberg I disagree, it's not about the optimization itself, it's about the knowledge
 
@Quill Maybe.
@skiwi Also see my comment to your question.
 
Yeah @Vogel612 it is a PITA, but even the regular old windows API is a PITA in this case. Likely because the whole thing was written before anyone was interested in automated tests.
The System.IO namespace is poorly designed.
Even the cross platform issues could be dealt with by a nice abstraction and platform dependent implementations though.
A lot like cross platform mobile development really.
 
Parents are playing music downstairs from my spotify
I can control what is being played from my computer
So. Freaking. Tempting.
6
 
@JeroenVannevel What songs would you like to play?
And then watch them blame each other on who changed the song? That'd be even more evil
 
@skiwi Gandalf-style?
 
@JeroenVannevel That song isn't too bad to be honest
 
3:22 PM
to non-nl: the song is titled "I don't live for you anymore"
Of course not. I'm a big Marco fan
 
Remember how Gandalf tricked the trolls doing that?
 
Guus Meeuwis too
Jeroen van Boom
all heroes
 
@JeroenVannevel Sounds like something to play at a divorce.
 
Now it's stuck in my head
 
Eddy Wally died so now I'm in Dutch schlager mode
 
3:23 PM
0
Q: Object to YAML (and viceversa) conversion in Scala

linkIn order to learn Scala, I'm writing a simple module that takes a Service object I defined and serializes it in YAML format. This is the definition of my Service class (and related): case class Image(image: String) case class ContainerName(container_name: String) case class Command(comman...

 
@Hosch250 it's about a breakup -- wrong kind of not living anymore
 
3:57 PM
This question may be better suited for Code Review. — JAL 19 secs ago
 
4:09 PM
I moved the question to Code Review as suggested: — Nicola Prada 16 secs ago
 
1
Q: Swift: How to avoid tight coupling with a Portfolio object made of Asset Classes and Securities?

Nicola PradaI am learning Swift and Object Oriented Programming. I am new to design patterns and protocol oriented programming. In my test code I have several related objects: Security: the most important object that will be contained in the other ones. AssetClass: Contains Securities objects Watchlist: ...

 
4:27 PM
@JeroenVannevel Yuck. Couldn't you find some Urbanus instead?
Heidevolk?
Anything but that.
It would give your parents a headache though, it's perfectly capable of that.
 
@Mast Heideroosjes?
 
questionable dutch metal
Much better
 
Does anyone have a spare vote for this answer (not mine, although the question is). Would put him on an even +10.
Not that Sunday afternoon is a good time to pimp an answer, almost nobody around and all.
Went to +11 anyway, good :-)
 
5:02 PM
Questions about improving working code are a better fit for Code Review. — Frédéric Hamidi 51 secs ago
 
@JeroenVannevel The Dutch attempt at Celtic Metal. I'm not sure any genre wants to be associated with it.
 
5:15 PM
If you have a specific problem (e.g. "I want to be able to click on button X and get effect Y"), please state it clearly (not "I don't know what to do after that. Please give me some advice." <= this is unanswerable!). If you don't have a specific problem and just want comments on your code, you better post a question on codereview. Good luck! — Dev-iL 44 secs ago
 
Thank you, Worldbuilding!
 
they should name their chatroom, The Observation Deck
 
5:36 PM
1
Q: Evaluating whether a 3 x 3 square is magic

ChuckI have written the following code for the project in the header. It was created as a win32 console app, empty. It is on Windows 10 and an HP Pavillion laptop with an AMD processor. I am using the following known good 3 x 3 magic square as input: 8 1 6 3 5 7 4 9 2 The first check_row itera...

 
As suggested by JAL I posted the question in Code Review: codereview.stackexchange.com/questions/119199/…Nicola Prada 29 secs ago
 
@CaptainObvious assert(square, magic);
 
Aaah close to 5k.
Monking.
 
Monking @Legato
I'm at 499 rep at MSE because a user was removed.
 
Not sure what you're talking about. :P
 
5:50 PM
possible answer invalidation by Stilltorik on question by Stilltorik: codereview.stackexchange.com/posts/119107/revisions
 
Thanks Santa :-)
@Duga Fixed and commented.
@Legato Post more questions.
My rep is also a bit stagnant, I don't post enough.
 
I posted and answered a few recently, but they weren't well received or the site in general is becoming more SO-like in that things are overlooked, but that could just be a fear.
 
It depends a bit on the tags.
 
0
Q: Vowels in a String are in Alphabetical Order

Jae BradleyTask Write an implementation that returns whether a String has vowels (English language) in alphabetical (A-Z) order or not. Feedback Is my vowels variable appropriate? Is there a better way to implement a vowel lookup? If a candidate String has no vowels, the validator will return true - is ...

 
6:07 PM
Take a look through these docs (up in the tree) as well: github.com/dotnet/roslyn/blob/master/docs/compilers/CSharp/…
also interesting
 
Oh boy. Overload resolution. Not as simple as one would think.
 
In Java it's fairly easy
In C# it's filled with lots of edge cases
 
6:25 PM
0
Q: Using GPIO - Controlling a forever loop with a button in C

jauntyThis is my first C program so please be patient. I am trying to control an "LED show" using the push of a button. The current code runs, but only goes through the show one time. I would like it to continue forever, until i hit the button and it exits, only to wait for me to hit the button agai...

0
Q: CSS & JS piechart

fazacI made a pieChart function thanks to the main css properties 'rotate:xdeg', 'border-radius:100%' and 'overflow:hidden'. That helped me to make rotating quarter pies of any size. Here is the code : function getRandomColor() { var letters = '0123456789ABCDEF'.split(''); var color = '#'; ...

 
6:44 PM
@RubberDuck What makes overload resolution special in regards to usual function overloading?
 
0
Q: Better way to write if else if

user1950349I have a below php script code: <?php if ($a == 'a') { somenewfunction(); } else if ($a == 'b') { anothernewfunction(); } else if ($a == 'c') { dosomethingweird(); } else { donothingatall(); } ?> Is there any better way to wri...

 
in a different language?
 
possible answer invalidation by Edward on question by Chuck: codereview.stackexchange.com/posts/119202/revisions
 
Things you find on SE...
@Duga Harmless.
 
I'm not sure what you mean @Mast.
All I know is that there was an entire chapter in Jon Skeet's book on it that made my head swim.
I never would've thought that there were so many corner cases and gotchyas.
 
6:59 PM
@RubberDuck What is special about Overload Resolution? I'm aware of Function Overloading, but what's so special about this thing?
 
0
Q: Custom sorting function implemented as a jQuery plugin

luqo33I was asked to create a jQuery plugin that would sort homogeneous DOM elements in a given DOM container element. I came up with the idea to attach data-priority attribute to the elements that are to be sorted, e.g.: <div class="offer-item" data-priority="10">..</div> , and later use that attri...

 
Overload resolution is what makes method overloading work if I'm understanding you correctly.
 
So it's the thing that makes the other thing work?
 
It's the thing the compiler does to tell which method is going to be called based on which arguments you passed.
 
Right.
 
7:05 PM
Function overloading is having multiple methods with the same name but a difference in parameters (amount or type)
Overload resolution is the process of determining which overload will be called given a set of arguments
 
The stuff under the hood.
 
Yeah. What @Jeroen said. So eloquent.
 
Jeroen does that, putting things eloquent.
 
It's surprisingly easy to end up with something ambiguous that can't be resolved.
 
Yea, I figured that out first time I learned you could pull that trick.
 
7:10 PM
Foo(int bar, object baz) {}
Foo(object bar, int baz) {}

Foo(1,1);
Contrived, but illustrates the point.
 
And all of a sudden the universe tries to compile itself.
2
 
Lol. That ^
 
6
A: Why do two methods with signature (primitive, wrapper) and (primitive, primitive) cause the method call (wrapper, primitive) to be ambiguous?

Jeroen VannevelAlright, I have taken a closer look at the JLS and I believe this should clear up any remaining doubts you might have. This is the original problem: public class Main { private static void flipFlop(int i, Integer iRef) { System.out.println("Method 1"); } private static void...

related
I love diving in language specifications
 
Be careful, if you want to give me some code optimization advice, please go here : codereview.stackexchange.com/questions/119209/css-js-piechart . Thanks for your help ! — fazac 5 secs ago
 
7:35 PM
@Duga That's about the only time I think a cross-post is legitimate.
 
If this code works, it should be posted at codereview.stackexchange.comcricket_007 31 secs ago
 
-2
Q: Why does casting this double to an int give me 0?

JacobSorry this has been confusing me for hours and nothing comes up on google about this. I'm programming in C, trying to convert decimal to binary, and I'm confused as to why this keeps giving me the right amount as input but the integer value is always 0. even if I properly cast input as an int, i...

 
No way this code passes code review in my organisation. Can't you write it in a clear and self-documenting fashion? — PreferenceBean 30 secs ago
 
Zak
7:52 PM
@Resonating spawning alternate realities in order to register uncountable sock puppets is against stack exchange policy. Please limit your upvoting to countable infinities in this time stream. — Yakk Apr 14 '15 at 13:28
on Worldbuilding, of course.
 
0
Q: TicTacToe game, need help in making it shorter (Python)

Javed HakimI'd just like to ask if there's anyway to make the functions play_Game() or is_move_valid() anymore efficient. For example using a loop of some sort, i haven't been able to figure out how and would like any help in trying to make those functions shorter. Any help will be much appreciated. #Tic...

0
Q: NodeJS Link Shortener

alanbuchananI made an app in NodeJS, with Express and Mongoose, that takes a URL as input into the address bar, and returns an alias to that URL. It can be used as a link shortener. The app is intended to fulfil this challenge's user stories: I can pass a URL as a parameter and I will receive a short...

 
8:21 PM
@Vogel612 Any news about the JChatExchange project?
 
not really...
 
that ^^ doesn't look very promising...
 
hoho
repo-shamed
 
I'm voting to close this question as off-topic because, since it is asking if working code is the correct approach, this is a code review question. — Quentin 43 secs ago
 
am I mean?
@Unihedro are we tomorrow yet? bwahahaha #GitHub #TomorrowWillBeGood https://t.co/ohuMJh27cC
4
 
8:26 PM
@SimonForsberg I can't nail the one developing on that down to committing to something
 
@Mat'sMug Yup :)
But I like it :)
 
If you want to give me some code optimization advice, please go here : codereview.stackexchange.com/questions/119209/css-js-piechart . Thanks for your help ! — fazac 37 secs ago
 
0
Q: Unity post/get/check www requests with success callback and error callbacks

ZephniThis is my first post on here, I was looking around for a forum where you can post review-able code for incite and counsel, hopefully I'm in the correct place! This is a class I built to handle post/get requests to URL's, but also check for connection and provide different callbacks depending on...

0
Q: C getline Implementation

BizkitI'm practicing my C coding and I wanted to implement my own version of the getline function in C for learning purposes. I'd like a review on coding style, correctness, improvements I can make for performance, and overall quality of the code. My main concerns are correctness and performance (in th...

0
Q: Safe, fully standards following integer abs in C

hydeHere's a bit tricky one, because AFAIK there is no existing platform, where conditionally compiled part of the code would actually get included by compiler, so it is entirely up to the human review to see if it is correct. The purpose is to have abs function, which does not trigger undefined beh...

 
9:00 PM
Naruto answer; accepted non-selfie answer with 0 score: Finding the object and the URL associated with a notification
Ripe zombie; open question with answers, at least one answer having score 0, no answer having score > 0: Multiple inheritance pattern for vehicle information
 
This question is better suited for Code ReviewCoryKramer 28 secs ago
 
9:17 PM
0
Q: CLI tool as an npm package written with NodeJS

mstruebingI wanted to know if you know anything which can be made better here. I've done this with a library boilerplate from airbnb. I didn't know what can be enhanced here. If you know something please let me know, I'm willing to implement all what you suggest. #!/usr/bin/env node import open from 'op...

0
Q: Validating ISBNs

SlayerI'm just looking for a cleaner way. Obviously I could store a variable for some of the int parts. Personally, I think the one-liner looks better and everyone's definition of what constitutes clean readable code differs. def gen_isbn(isbn): for i, val in enumerate(isbn): if len(isbn) =...

0
Q: Optimize PHP crawler

dreamPrI have code that parses thorught web pages finds commentaries and saves commentary info in DB. I have array where all necessary pages are stored. I iterate throught all theese pages one by one and find HMTL element which contains all the info about commentary if there are multple pages with comme...

 
9:34 PM
monking
 
monking
Anyone here has used Windows 10 a good bit?
 
Zak
@Phrancis A little, not a lot.
 
9:49 PM
Just looking for someone to say if it's pretty good, awesome, or disappointing and why (we can take this to Nth)
Shopping for a new notebook and I find the Apple products are prohibitively expensive for how good they appear
So, I'm seriously considering a Windows notebook instead
 
@Phrancis It's bearable.
 
Is it less bad than 8?
 
Less than 8, definitely. Equally bad as 8.1.
Well, different bad.
 
@Phrancis just buy a blank machine (not so easy to find) and install Linux
 
I didn't know there was a difference 8 vs 8.1
 
9:56 PM
8 was the really crappy original.
And yes, I'm running a dual-boot as well. Ubuntu 16.04 LTS (recently upgraded) and Win 10.
 
@Caridorc Yeah I really don't want a Linux machine right now, I've entertained the idea though. I want to be able to do some PC gaming
 
Best of both worlds.
 
Dual boot is an option, though I'm not sure what I'd use Linux for
 
Play heavy stuff like Planetside 2 on Windows side, use the suites that don't work on on Linux on the Windows side as well, throw most of the development to Linux side.
 
personally, I'd go with an Apple laptop and a windows Desktop
 
9:57 PM
He's talking notebook, not desktop.
 
Also Wine & Crossover run most decent programs on Linux / Mac these days anyway
 
Wine will not run Altium decently. You also will not want to use it for heavy gaming.
I can imagine there are a lot of heavy things it won't run smooth.
 
Yep
 
Something like Arma through Wine doesn't sound good, but these days everything's being ported to Nix for Steam Box anyway
 
If you want the best of both worlds, go dual-boot.
 
9:59 PM
I'm putting some models side-by-side for comparisons, as you can see Apple are way higher price for the specs
 
@Phrancis No surprise there ^^
 
And really, $1299 and all you give me for storage as 128 GB flash??
(and not easy or cheap to upgrade)
 
@Phrancis Try Asus. They got a couple of good ones as well.
 
SO is not a code review site! — Olaf 45 secs ago
 
10:01 PM
you also gotta remember that OS X takes less memory usage to run the OS
 
OK, got a few others on my list, I'm trying to stay in the $1000 range or so
 
and yeah, the storage is horrible
I put together a list for a new gaming pc the other day actually, and it came to $4000
 
Razer and Alienware have some serious contenders in that price bracket also
 
you can spend a lot of money both ways
 
Let me find you a very specific one that may or may not suit your needs.
 
10:03 PM
Oh yeah, for sure. Not looking to do really heavy gaming or anything, Alienware does have a really promising standalone graphics upgrade box that can plug to their laptops to mount full-size GPUs... dell.com/us/p/alienware-13-r2/…
 
How about something like a Asus N551JB-CN083T?
Go for around 900 Euro here.
Otherwise you could always try Hardware Recommendations
 
in The Nineteenth Byte, 13 mins ago, by PhiNotPi
I saw this floating around on Reddit, check out the subtitle of this article: http://www.independent.co.uk/life-style/gadgets-and-tech/news/whatsapp-group-cha‌​ts-bigger-maximum-size-256-people-users-a6856491.html
in The Nineteenth Byte, 12 mins ago, by PhiNotPi
> WhatsApp increases group chat size limit to 256 people
> It's not clear why WhatsApp settled on such an oddly specific number
 
OK I'll put the ASUS one in my list, but I don't seem to be able to find that model in USA retailers
@Quill lol that's precious
 
An SSD upgrade with that asus would be good too
room for your operating systems and ides
 
Is that what SSDs are for? I was wondering about that
 
10:11 PM
SSDs are for anything you want to run faster
 
@Phrancis I can get you other types that should fit your needs as well.
 
Mainly used for operating systems, but if you think your IDEs are priorities then those too
 
Going to bed now though, so that will have to wait till tomorrow.
 
-3
Q: Code Review should be option when voting to close SO question

whytheqWhy isn't Code Review an optional alternative site suggestion, to move a question to, when voting that a question is off topic? I think that is where this question needs to go: MDX Efficiency, measures from the same Hierarchy (in Excel VBA)

 
@Mast OK don't worry I'll check what newegg has for Asus
 
10:12 PM
@GrimaWormtongue two duplicates lol
 
@Quill At least ^^
@Phrancis You may be able to find yourself one with a GTX card in them, those are quite a lot better than the regular ones.
With a bit of luck they are almost the same in pricing for odd reasons.
Just something to keep in mind.
 
hey @Mast do you mind if I ping sometime to ask about Motherboards, I'm a bit fuzzy on them
you seem to know what's up
 
@Quill Sure, will read it when I'm back on.
You guys know where to find me anyway.
 
0
Q: Remove comments from C source file

venugopal reddyI wrote the below program to remove comments from a c source file. Accepting file name from command Prompt. Suggest me If I missed anything or any Improvements that can be made in the program. #include<stdio.h> #include<stdbool.h> void m_cmnt( FILE *fp ) { int prev=0 , c...

0
Q: JavaScript - is this how short-circuiting works?

user5680735I've been researching quite a bit about technology. I recently ran into a theory on how JS evaluates expressions. The topic is called short circuiting Here's how it works If presented with multiple conditions, if the first one evaluates to true JavaScript doesn't even bother reading the remaini...

 
The MSI and Lenovo so far have GTX GPU
 
10:21 PM
Asus ROG GL552VW-CN108T goes for almost a thousand Euro here, not sure what the USA price is. That's one beast of a laptop.
Possibly this one on Newegg
 
This question would be a great fit for Code Review. — Zak 20 secs ago
 
@Mast That's one hell of a beast, might even be interesting for me
 
10:36 PM
I'm voting to close this question as off-topic because it belongs on codereview.stackexchange.comLuke 14 secs ago
 
The ROG range of computers are pretty beast setups
 
@luke you see this right at the top of the code? "*This Source Code is NOT real". Example code and hypothetical Code are both Off-Topic on Code Review. — Zak 5 secs ago
2
 
lol @zak
 
@Luke In which case, VTC for the correct, SO-specific reason. "Because it belongs on Code Review" isn't, in and of itself, a valid close reason. — Zak 13 secs ago
 
By that argument, one should avoid if-statements, Loops and about everything a programming language uses, because at the basic level, it's all just fancy goto statements. — Vogel612 8 secs ago
2
 
10:55 PM
If your code is working correctly, you could ask on Code Review for any pointers on style and implementation. — Jongware 8 secs ago
 
0
Q: Database of students

prestokeysAt first, I had Database to contain std::list<Student> students, but because there are over 2000 students, searching by students should not be done in linear time. However, searching for students can be by name or by student number. To enable both searches in logarithmic time, I decided to give...

0
Q: Please could I have some suggestions how to better this Java code

huskyprogrammercould you please let me know if there are any improvements I could make to this Sorting code. I understand that there are built in sorting routines, just implementing my own sort method as an exercise! Thank you in advance! import java.util.*; public class Sort { public static ArrayList<Name>...

 
00:00 - 23:0023:00 - 00:00

« first day (1009 days earlier)      last day (3008 days later) »