« first day (2414 days earlier)      last day (77 days later) » 

12:00 AM
RELOAD! There are 6300 unanswered questions (90.0789% answered)
 
 
2 hours later…
1:32 AM
0
Q: Scanning macro in NASM Win16 syntax for DOSBOX (Intel 8086)

T145Supports backspacing, but not wrapped backspacing. %macro newline 0.nolist mov ax, 0E0Dh int 10h mov al, 0Ah int 10h %endmacro %macro getc 0.nolist %%get: mov ah, 11h int 16h ; get keystroke status jnz %%pressed hlt jmp ...

0
Q: Complete Intcode Computer (Advent of Code 2019: Day 9)

trentclMy best languages are Python and Rust, but I want to improve my C++ skills, so I decided to try my hand at Advent of Code 2019 in C++. So far I have not encountered too many issues, but I want to know what I am doing that is subtly (or not so subtly) wrong. The following program is my solution t...

 
2:00 AM
possible answer invalidation by Kunal Tyagi on question by Kunal Tyagi: codereview.stackexchange.com/posts/233909/revisions
 
2:37 AM
codereview.stackexchange.com is where you should post this question — Harshal Parekh 23 secs ago
 
2:55 AM
0
Q: Generic linked list written in C programming language

AmitI have been trying to come up a generic C linked list to store data as it comes and later sort them to use it for various purpose. Please have a look at the code below an provide me your review comments. This code compiles and runs in Windows and Linux. 1. Design 2. Quality 3. Usability you ma...

0
Q: Technique to Simplify Data/Key Reuse

WillMy app's navigation module needs me to provide a route name for each screen in the navigation stack. Previously I used clean, strings like Sign In, Overview, Sign Up, etc. The header shown on each screen needs a title to display, so I simply showed the route name of the current screen as the ti...

 
3:32 AM
Hi @Danny, I think you need to make the question more concise. I'm sure you're already frustrated, so I'm sorry to ask you to do more in light of that. Sounds like you've been at it for a while. Don't give up. If I were you, I'd perhaps focus on the first part of the question for this Stack Overflow question. Step 2 isn't really clear on what you're asking. If you're looking for code review, I'd check out Code reviewbeauk 7 secs ago
 
 
1 hour later…
4:53 AM
Monking
@Duga fixed a small bug mentioned only in comments
 
0
Q: how to switch views in Swift from a Button(action: {}) {} or DispatchQueue.main.asyncAfter() or others?

Julian TiemannI am trying to programmatically change views in my macOS application. I found stuff like NavigationLink and others but I am not allowed to use them. The code to switch must be in Button's action, because this way I know that I can quickly switch from the code, even if it is not in button format....

 
5:15 AM
possible answer invalidation by Jamal on question by Jamie Bovington: codereview.stackexchange.com/posts/233937/revisions
 
5:46 AM
"Is there a better way to do it" is kind of opinion-based. This likely belongs on Code ReviewHerohtar just now
 
6:39 AM
@SᴀᴍOnᴇᴌᴀ IIRC there was a bug where someone had 1.4k links to a post but no announcer. SE staff commented saying they were going to fix it
 
7:20 AM
Monking
Just got announcer on 3 questions (3 different sites). Don't remember linking to 2 of them, one of them I'd never voted on so I suspect I never shared it to begin with...
@SᴀᴍOnᴇᴌᴀ And IIUC they now count clicks from within the SE network as well.
 
7:45 AM
0
Q: JS Highlight tool with multiple buttons

Cameron SkidmoreI am trying to create a website to present a research paper and I want to be able to have the in text citations as links as links and when you click them, they highlight that particular source. I tried the div:target identifier like this: Python: <a href = "#source1">(Nama, 29)</a> <div id = "s...

 
That question is to broad for SO. You should post on the Code Review site instead. — jmcilhinney 54 secs ago
 
8:06 AM
0
Q: Interlock of some equipments in electrical power system using simple Arduino Uno code

A. AliI'm trying to implement some logic functions essential to control a small power system consisting of 2 Transformers labeled T1 and T2, 2 Generators (G1 and G2) and a bus tie (BT). I'm not going to overwhelm you with the unnecessary details. I need help figure out why my Arduino circuit doesn't w...

 
8:21 AM
Which can be found hereAConfusedSimpleton 36 secs ago
 
8:55 AM
Do it somehow, then show complete piece of code on code-review. Asking in advance is tempting, but is unlikely to give you answer you expect. — Sinatr 49 secs ago
 
9:29 AM
0
Q: Postgres zero downtime fast full insert of table

Peter Mølgaard PallesenI have a large table with many indexes and some activity. No foreign key constraints included(eventhough there are columns representing foreign keys). I event based updates the table from an outside source but every once in a while I perform a full reload, due to the risk of not recieving all eve...

 
I'm voting to close this question as off-topic because it's "How can I improve my code" kind of question therefore, it's more suitable here: codereview.stackexchange.com. — Sebastian Kaczmarek 12 secs ago
 
9:43 AM
I'm voting to close this question as off-topic because it belongs on Code Review. — Andrew Morton 42 secs ago
 
I don't know if I have left something for another answer of this C# question: codereview.stackexchange.com/questions/232510/… I have put a 50rep bounty on it (spend some rep because of winterbash) so another answer would receive it.
And I don't need any upvotes for the answer.
 
10:20 AM
possible answer invalidation by Lokesh Agrawal on question by Lokesh Agrawal: codereview.stackexchange.com/posts/225757/revisions
possible answer invalidation by Lokesh Agrawal on question by Lokesh Agrawal: codereview.stackexchange.com/posts/224136/revisions
possible answer invalidation by Lokesh Agrawal on question by Lokesh Agrawal: codereview.stackexchange.com/posts/225972/revisions
 
@Duga rolled back
 
-1
Q: Inheritance (basic level) what's the best way to ask the user the width and height? (shapes example)

neilpareI made this program to understand inheritance better. Now that I'm at this basic level it's not really a problem but I can see this coming in the future and so I'm asking what's the best method to ask the user to insert the width and height of a rectangle (in this case). The code I'm providing ...

 
10:40 AM
@Dharman without knowing what libraries or functions their include file has, it is not possible to ascertain what it returns or which functions to call to provide an equivalent solution. I answered the OPs specific question using the code they provided. I directed the user to use prepared statements and provided an example albeit external. Anything beyond that is outside of the scope for StackOverflow and are better reserved topics on CodeReviewfyrye 51 secs ago
 
@Heslacher those were all different posts. I picked up the other two
 
"I wonder: how optimal is it and, if it's bad, how to optimize it?" This question is out of topic for StackOverflow, but very welcome for CodeReviewCid 36 secs ago
 
Ah, ok thanks. Made me wonder if Duga went ballistic.
 
If it just works and you are in need for some code reviewish thing, check: codereview.stackexchange.comvahdet 51 secs ago
 
 
1 hour later…
11:53 AM
0
Q: Bubble Sort with tests

bhathiya-pereraI've become a bit rusty in Java. This is an attempt at brushing up my skills. Bubble sort, sometimes referred to as sinking sort, is a simple sorting algorithm that repeatedly steps through the list, compares adjacent elements and swaps them if they are in the wrong order. The pass through th...

0
Q: Iterated Prisoner Dilemma Haskell implementation

Fabian SchneiderA collegue and me implemented a simulator the iterated prisoner dilemma from game theory in haskell. We would appreciate any feedback on the quality of the code, how things could be worked out more efficiantly or elegantly. The code file together with a tex file in literate haskell style that ex...

 
12:13 PM
0
Q: Comparing arrays with source questions and user answers

Слава ИвановI'm trying to realize simple testing application. And I ran into a problem. I have two arrays. The first is an array with the initial questions, the second array is the answers of users. And now I need to count the number of correct answers. I wrote the following code. I wonder: how optimal is it...

 
12:24 PM
 
12:55 PM
possible answer invalidation by Padmanabhan-Paddy on question by Padmanabhan-Paddy: codereview.stackexchange.com/posts/233868/revisions
 
1:28 PM
If your program works correctly (to the best of your knowledge) but needs to be improved for larger strings then Code Review is a good place to ask. They have dedicated tags [programming-challenge] and [time-limit-exceeded] for this kind of question. – Make sure to read their FAQ first for a proper title and description of the problem. A concrete example of a string for which your program is too slow would be helpful in any case. — Martin R 16 secs ago
 
@Heslacher Has happened before...
Fun reading:
Sep 28 '15 at 1:05, by Duga
possible answer invalidation by janos, xtrimsky on question by xtrimsky: http://codereview.stackexchange.com/posts/105857/revisions
Sep 28 '15 at 2:11, by Ethan Bierlein
Hello, I see Duga is broken. How has everyone's night/day/whatever been going?
 
1:53 PM
If you want a review of the code, really, post on codereview. That is the purpose of the site. If you review my account, I've posted there a few times and have gotten amazing feedback. — wundermahn 7 secs ago
3
This seems like a question better suited to codereview.stackexchange.comQuentin 40 secs ago
 
0
Q: Is there a better/cleaner way to assign values based on the result of radio buttons?

GlazbeeI have 3 radio buttons all grouped inside a group box in a WinForms project. Currently, I am checking which button is checked and assigning values using the following if/else statement, similar to the below example if (rb1.Checked) { selectedButton = 1; se...

 
2:17 PM
0
Q: Minimum window substring time limit exceeded for a swift solution

Vaibhav SinghBelow is my code for minimum window substring in swift, I can't figure out why the Leetcode online judge says time limit exceeded, my solution seems o(n), any help is much appreciated. Here's the link to the leetcode problem: https://leetcode.com/problems/minimum-window-substring/submissions/ f...

0
Q: how can i get compound word's list in suggestions using jazz spell check with java

Srikanth TogaraThis little program was written for an assignment in a data structures and algorithms class. I'll just note the basic requirements: Given an inputted string along with mode(0=spell check , 1=AddToDictionary), if the mode is 0 the program should check to see if it exists in a dictionary of correc...

 
2:32 PM
Yes this will be closed, but you can try to submit it to the code review stack exchange, I would advise to make a full realistic example, this one is not syntactic and it is confusing. Having many parameters is sometimes necessary, and some prominent package do it, but if it really describes different functionalities, make you lr main function into several ones, or write simplified wrappers around the main function. — Moody_Mudskipper 18 secs ago
 
 
1 hour later…
3:32 PM
Found my Hat(s)
 
0
Q: Functional Programming approach to a REST API example: Is this a good example?

Karl MorrisonI would like to know if there are any things I could improve with the following code regarding writing it in a FP style: server.js: const express = require('express'); const app = express(); const person = require('./person'); app.get('/create-person/:name', (req, res) => { person.addPerso...

0
Q: Human Jug and Glass

JencyI am a beginner in Java. I have created this small project with Java with the inheritance concept. Here the Human will fill, pour and drink water. There are three classes Glass, Jug and Human. Let me know how u think it is! //Glass class: public class Glass { private float capacity = (floa...

 
3:49 PM
Please help a poor bot get a hat! Upvote this question:
24
Q: Simon, Mat's Mug, what's the (rating) difference?

DugaThis is a part of the code for the almighty bot @Duga (That's me!). Every evening, 15 minutes before "RELOAD" (00:00 UTC), I post the reputation differences for some Code Review users. Example output is: Mat's Mug vs. Simon Forsberg: 2728 diff. Year: +3618. Quarter: +885. Month: +648. Week:...

 
@Duga sorry, I did it long time ago.
@Duga you should just upvote codereview.stackexchange.com/questions/233946/… to get a hat.
 
0
Q: Compare Common and Uncommon files separately

Abdul Rahman SherzadI have following file: STUDENT_D19001.T103412_HU.txt STUDENT_D19001.T103412_KU.txt STUDENT_D19002.T113030_HU.txt STUDENT_D19002.T115055_KU.txt STUDENT_D19003.T115055_KU.txt STUDENT_D19004.T135040_HU.txt I want to process the common/pair files separately in this order (HU1 and then KU1; HU2 an...

 
4:18 PM
Monking
@Duga done
 
@Heslacher Warm welcome or what is that?
 
4:31 PM
yes
 
Monking
 
Now posted on Code Review: codereview.stackexchange.com/q/233978/35991. Perhaps you want to delete it here? — Martin R 38 secs ago
 
This advice is about the code and should go in an answer, right?
In regards to your REST API. It is common to send POST instead of GET to create a resource. The HTTP methods (verbs) are meant exactly for this differentiation between operations. Use POST /person to create new person. Use PATCH /person/:name to update existing person. And GET /person/:name to get existing person's data. Or at least that is the usual way... — slepic 17 mins ago
I left a response comment advising to put that in an answer but user is arguing that it doesn't make any observations about the code...
@SᴀᴍOnᴇᴌᴀ I don't think my comment makes for a decent code review and so I didn't post it as answer. Firstly, it would change the api to become something different then current working code. Secondly, I didnt make any observation about the code itself and I don't think I will... — slepic 2 mins ago
 
This seems like a question better suited to codereview.stackexchange.comQuentin 43 secs ago
 
5:02 PM
0
Q: simplying foreach-loop for Frequency analysis for simultaneous dice rolls

alecHey guys had another question for my perl-class asignment. related question: Frequency analysis for simultaneous dice rolls use warnings; use diagnostics; use GD::Graph::hbars; use List::Util qw(max); my $number_of_dice=0; my $number_of_rolls=0; my @total_sum_of_eyes; my %count; ...

-1
Q: Assigning jobs in a functional style

James BatesonI'm new to F# and functional programming in general (coming from an object oriented background). I just wanted to get some criticism on an algorithm for assigning jobs to crew members. I want to be as functional as possible and avoid loops and mutable state. Here is what I've come up with. let r...

 
Anyone ever think of what a junior could do in this code without knowing? Changing the order of enums seems benign and wouldn't really be caught in code review. Changing an existing name of an ENUM that is known to be stored in the db is something that will be blatant in code review and will be addressed. Have to think more on the side of maintainability on this side, because the downside of getting the ENUM type wrong could be disastrous. Especially if the update is released, and new data (with new ordinals) is mixed with old data (with previous ordinals), good luck fixing that! — Zoidberg 59 secs ago
 
5:44 PM
0
Q: My first ASF Maven commit -- don't understand the maintainer

BenI created my first commit for ASF Maven today. In the PR I was asked two things. By the way: "understand" doesn't mean I speak another language. It is more about his and my opinions and arguments. Else-If instead of guard statements / early return So, there is no documentation and no check styl...

 
6:03 PM
@MathieuGuindon No, but that was pre-LCC, FTR.
That was back when it was Hypothetical, Example and LCC, IIRC.
@CaptainObvious Why is this -1?
I see no reason it should be, looks like a solid question.
 
maybe somebody was upset they didn't get a hat yet
 
@410_Gone All of those fall under the same reason. It used to be Ownership, explanation of code and LCC.
 
Right, but now they have their own alternative reasons, so LCC is less important. (Most of the previous use was hypothetical or example.)
 
I don't understand you
 
Nevermind, it's not important anyway.
 
6:16 PM
Question might be better suited for codereview.stackexchange.comNikki9696 46 secs ago
 
0
Q: Pandas step rolling window for features calculation

Nestoras ChalkidisI have a pandas data frame and I want to calculate some features based on some short_window, long_window and bins values. More specifically, for each different row, I want to calculate some features. In order to do so, I move one row forward the df_long = df.loc[row:long_window+row] such as in th...

 
6:46 PM
0
Q: Javascript To Do Application

btow54I've created a simple JS 'To Do List' application. I'm very new to JS and this is the first JS project I have done. I would greatly appreciate any feedback on how to make the code more efficient, neater and better adhere to best practices. The 'To Do List' uses local storage to persist data, and...

 
 
1 hour later…
7:48 PM
-1
Q: Why doesn't my number sequence print from the 2d arraylist correctly?

DevI cannot get the loop to work in the buildDimArray method to store the number combinations "11+11", "11+12", "11+21", "11+22", "12+11", "12+12", "12+21", "12+22", "21+11", "21+12", "21+21", "21+22", "22+11", "22+12", "22+21", and "22+22" into the 2d arraylist with each expression going into one c...

 
8:08 PM
0
Q: Bash script to scp specific, most-recent files from remote server

dylanjmI'm writing a helper script that I wish to be able to share with my co-workers. We all work using macOS Mojave, but all have their own shell configurations. For example, I actually use ZSH and bash 5.0. There are often times where I am working with data that is output from our nightly testing t...

 
8:22 PM
@crashmstr Damn he got a reject vote! But wait... this isn't code review stack exchange. Are you lost? — reg 6 secs ago
 
8:54 PM
I would like to reduce this to the fewest possible lines of code. => Code ReviewÇöđěxěŕ 43 secs ago
 
9:08 PM
@Klaycon Reworking the sentence for "by the standards i would apply in a professional development context, that code pattern would fail" would have made him appear much less like an cocky user. But the way he phrased it, on top of a lack of valid argument, was plenty arrogant. The kind that you'd never wish to have as a code reviewer. — reg 51 secs ago
 
9:24 PM
@MattiPrice syntax, the whole question in general is how can I speed it up, it's not suited for here, better at Code Review IMHO. Is it an issue to provide constructive criticism? — Çöđěxěŕ 10 secs ago
 
9:51 PM
0
Q: Should we create named string constants in Java when the usage is obvious (reading of named settings from the XML))?

Александр Сергеевич ДжусUsually it is a good style in Java to create named constant for string (and other) hardcoded values. Using the example below I want to know how pedantic should I be in it. I use java class as a wrapper of XML settings. each function is suppose to return a value from related XML file. I defined...

 
10:12 PM
1
Q: Fixed size 2d array of objects

karthickMy Objective is to create a fixed column array object of size 4 columns so that I can form a 2d array in the following format which I can use to print to a pdf later. The solution is working fine. But need help in figuring out if there is a better way to implement this. let input = [{ id:123, ...

0
Q: Simpler way to write this

CatfishIs there a simpler way to write this ugly if/else statement? It's simply appending a query string to a url depending on whether the variables exist. if (start) { url += `?start=${start}`; if (end) { url += `&end=${end}`; } } else if (end) { url += `?end=${end}`; }

 
10:33 PM
0
Q: LINQ extensions for sequence comparing

Dmitry NoginLINQ extensions to compare sequences The desired behavior would be: [TestMethod] public void Compare_Value_Identity() { var source = new[] { 1, 2 }; var modified = new[] { 2, 3 }; var (inserted, deleted) = source.Compare(modified); CollectionAssert....

-2
Q: Iterate over just two or three numbers

DragonGamerPerhaps a dumb question, but what is a "nice" way to execute a piece of code with the indices 5, 7 and 9 for example (in c++)? Surely I can do something like: for (int i = 5; true; i += 2) { // Do something with i which is once 5, once 7 and once 9 // Code that i...

 
Just a heads up: once you have complete runnable code, post this over on Code Review. I see multiple other improvements that can be made, but that's beyond the scope of Stack Overflow. — Carcigenicate 11 secs ago
 
10:50 PM
This question has a good answer, but I think the code is broken. codereview.stackexchange.com/questions/233961/…
 
0
Q: Am I wrapping synchronous code in ktor/Kotlin coroutine correctly?

art-solopovI'm playing with ktor right now. If I understand this correctly, code in ktor's handlers need to be as asynchronous as possible. So I was trying to figure out how do you write synchronous (potentially expensive) code in a Kotlin coroutine. Here's what I've written: install(DefaultHeaders) ...

 
11:35 PM
0
Q: Java - Trying to create a drivers license exam program using methods

VGF2626I am trying to write a program that grades the written portion of a driver's license exam where the user needs to answer 15 out of 20 question correctly to pass. There should be a method that will allow the user to enter in their choices. Include input validation and only accept the letters A, B,...

 
I think you might want to try codereview.stackexchange.com for this question. — warped 17 secs ago
 

« first day (2414 days earlier)      last day (77 days later) »