« first day (2456 days earlier)      last day (1547 days later) » 

12:00 AM
RELOAD! There are 6367 unanswered questions (90.0876% answered)
 
12:30 AM
possible answer invalidation by Jefferson on question by Jefferson: codereview.stackexchange.com/posts/236028/revisions
 
0
Q: Is this proper usage of if__name == '__main__'

zstarIs this the correct usage of if__name == 'main'? I'm new to Python and am not entirely sure. Also, any other suggestions will be greatly considered. I am calling an API, first using PUT then GET. import requests import json import time #calling historical api, we must do a put request and the...

 
@Duga rolled back
 
 
4 hours later…
4:20 AM
0
Q: Rust Iterator Fizzbuzz

S0AndS0Rust is one of my first forays on a strongly typed language, beginning to like it's strictness, and am looking to improve my comprehension. Questions Are there any mistakes that the compiler hasn't pestered my about? The iterator increments or decrements, any other directions it should go? It'...

 
5:12 AM
Monking
 
5:42 AM
0
Q: Multi-threaded HD Image classifier using a neural network

bullseyeThis is a follow up to the code found here: Multithreaded HD Image Processing + Logistic reg. Classifier + Visualization Description: This code takes a label and a folder path of subfolders as input that have certain labels ex: trees, cats with each folder containing a list of HD photos corres...

 
5:55 AM
I couldn't get the network load balancer working. I have multiple MySQL instaces, the straight forward solution was to use a multihost connectionstring, but MySQL Connector/Net had a bug, and was not working with multiple host... The bug is fixed now (after 2 years) so i no longer need a network load balancer. See this link for more info: codereview.stackexchange.comHooman Bahreini 37 secs ago
 
6:51 AM
Monking
@pacmaninbw Modern compilers are so forgiving, it's hard to say what does and doesn't break C nowadays.
Half the things are undefined behaviour anyway.
 
7:03 AM
0
Q: Is the usage of JSONObject and JSONArray is correct, as it take lot of time to render UI

user9634982I am working on struts 2 based web application, where an Action Class render 7000+ records in UI. The query which fetches the record is already been optimized by the DB developer, but instead it took around 7+ seconds to load UI it also freeze the UI for a moment,on deep inspection I have found t...

 
7:21 AM
@SujayDSa: I couldn't get the network load balancer working. I have multiple MySQL instaces, the straight forward solution was to use a multihost connectionstring, but MySQL Connector/Net had a bug, and was not working with multiple host... The bug is fixed now (after 2 years) so i no longer need a network load balancer. See this link for more info: — Hooman Bahreini 9 secs ago
 
7:38 AM
How seriously can we take the "viewed" figures shown? There seem to be some extreme artefacts, enough for me to doubt them. eg several of my questions have view counts which grow at "a few views per hour", and then they suddenly (within one hour) jump by several hundred or even thousand. Not credible?
 
7:56 AM
@OliverSchonrock usually the view counts are at least semi-accurate from what I know
It's public knowledge that not every pageload counts as view and that the views are tied to IP in some way shape or form
 
0
Q: Python Implementation of Canopy Structural Dynamic Model using scipy.optimize.least_squares

ABCI am using the least_squares() function from the scipy.optimize module to calibrate a Canopy structural dynamic model (CSDM). The calibrated model is then used to predict leaf area index (lai) based on thermal time (tt) data. I tried two variants, the first did not use the "loss" parameter of the...

0
Q: Best way to return a pdf from a pyodbc row in flask?

Alias_KnaggI have figured out two ways to return a pdf from a pyodbc row with flask. ( the row data must be gunziped too in this case ) With a simple timing decorator I can find no obvious difference in speed. I was hoping the later version would avoid loading the whole pdf into memory, but I now realize I ...

0
Q: Matlab: Vectorizing equations for fsolve

Aristide HerveI have a system of 49 equations and 49 unknowns. All equations have the following form. where s = 1,...,S with S = R = 50 and T = 30. The a's, the b's and x_{50} are known parameters. Since all equations have the same form, I believe that vectorizing the problem is possible. I appreciate any ...

 
8:25 AM
@OliverSchonrock if your question becomes a hot network question like "high-performance-txt-file-parsing" the view count is expected to jump high
 
"hot network question"? Is there such a "flag or status"..which is reached at some point? That would explain it perhaps
 
There is a little clock below the vote buttons which will show you the timeline of your question. There you will see Jan 9 at 4:22 history became hot network question
Nobody, at least no normal user, knows the trigger of when a question becomes a hot network question.
 
possible answer invalidation by Xamtouo on question by Xamtouo: codereview.stackexchange.com/posts/236070/revisions
 
@Duga thats ok, just added some examples
 
@Heslacher (thumbs up) Got it., makes sense. And yes the other question where this happened has the same thing. Mystery solved. Thanks
 
8:38 AM
no problem
 
@Heslacher I am guessing "network" here means "all the SE sites", not just CR? It would have to, to get that traffic in that short time..
 
yes
 
0
Q: Genetic Programming - Pathfinding not enougth couples

Peter RaderI do genetic programming. I have 5 parcours, the first on the left is the easiest parcour. The first parcour can be solved by place one belt in the middle pointing downwards to solve the problem. If placed in the middle downwards, the puzzle is solved because the iron-ore flows downwards to th...

 
9:05 AM
0
Q: Suggestion for refactor Dynamics 365 webresource functions

Dipendra ShresthaCurrently my solution for calculating wages based on average weekly hours and any other wages field is very long and elaborate. I think it can be concised and make more readable but when I try to do it it creates some nasty bugs as it is based on field changed. Any elegant refactoring suggestion ...

 
@OliverSchonrock Yes, it's the list on the right side of your screen. Network-wide, so it could generate a lot of traffic.
Questions hitting HNQ (Hot Network Question) status can sometimes generate 30-40 votes the first day alone.
 
9:25 AM
0
Q: Runtime Error in Hackerrank challenge (Python)

Kshitiz KoiralaChallenge taken from Hackerrank. Available at: https://www.hackerrank.com/challenges/30-dictionaries-and-maps/problem?isFullScreen=true The challenge was to add a number of entries to a dictionary and then return the keys and values as queried in the format of "Key=Value". I solved the problem ...

 
9:39 AM
Code Review - For starters, the elif can just be else, but not sure how many microoptimisations you're looking for — Sayse 15 secs ago
 
9:50 AM
If you post this question on Code Review could you 1. Change the title to describe what you code is doing 2. Add a very short description - a link to Wikipedia would probably suffice. 3. Move your title to the question body. — Peilonrayz 30 secs ago
 
 
1 hour later…
11:00 AM
I think this question is more suitable for codereview.stackexchange.comMorpheus 21 secs ago
 
0
Q: Prefix all lines on standard error

cevingIs this the best way to prefix all lines written by a Bash script to standard error? #! /bin/bash exec 3>&2 exec 2> >(sed 's/^/ERROR: /' >&3) echo stdout echo stderr >&2 I am wondering, if I have to close file descriptor 3.

 
11:27 AM
0
Q: Tiny JavaScript Animation Library

EnijarI've created a tiny (723 bytes compressed + gzip) animation library. Is this a good way of animating arbitrary numbers? const map = (value, x1, x2, y1, y2) => (value - x1) * (y2 - y1) / (x2 - x1) + y1; const clamp = (value, min, max) => Math.min(Math.max(value, min), max); // Courtesy of @gre f...

 
11:57 AM
I'm voting to close this question as off-topic because the questioner ask for code review. — reporter 39 secs ago
@reporter this doesn't seem to be a code review to me as the OP is asking to amend functionality. It does however require more detail, as there's not enough context to understand the issue — Rory McCrossan 53 secs ago
 
12:48 PM
0
Q: Transform an object into another object structure

Dan CantirI've got such an input object, which I should modify in order to use it with some charts library. const input = { foo: { bar: 'biz', }, statistic: { "2019-11": { A: 11, B: 11, C: 11, D: 11, E: 11, }, "2019-12": { A: 12, B: 12, ...

 
1:24 PM
@Heslacher actually there is a semi-public hotness formula
 
0
Q: SQL Server - Avoid cursor while serial update

Stelios BobHow can I avoid use cursor to implement the following? I read that it can be done with CTE but I didn't get it working with the same result. In the example I am using two tables, the first one is the holders table containing a list of people and the transfers table where each transfer indicates ...

 
2:10 PM
0
Q: Disable expired User Accounts and removes group membership

BrownoI have pieced together the below. However it will only run in Powershell ISE and I cannot work out where I am going wrong. Import-Module ActiveDirectory #Get expired student AD accounts that are not disabled. $ExpiredUsers = Search-ADAccount -AccountExpired -SearchBase 'OU GOES HERE' Write-Outpu...

 
Still unanswered, despite a 200 bounty :(
21
Q: BF welcomes Fibonnaci

Simon ForsbergSlightly inspired by a previous question/april fools joke I decided to take on Fibonnaci sequence in the lovely language Brainfuck. In order to do this I have also worked on Brainduck, which is a Brainfuck tool/analyzer/IDE. In Brainduck I added the functionality to run Groovy code if the line b...

We need more Brainfuck reviewers.
 
2:30 PM
0
Q: Angular 8 - compare an X value from an array A to an array B, to retrieve the value Y from array B

Gregory HessI have an "update" form for users. - I have a drop-down field with the list of countries: countries = [{code: "BE", name: "Belgium"}, {....} ...] The user ( from a Observable with name "user"): user = [name = "Arthur", country = "BE", ...] In the observable from user, I don't have the country n...

 
Ryan Donovan on January 24, 2020

Welcome to ISSUE #9 of The Overflow, a newsletter by developers, for developers, written and curated by the Stack Overflow team and Cassidy Williams of React Training. You can read more about it here. This week, we get a peek into the future of Stack Overflow, discover the longest possible free ride, and check out a mobile OS made from React Native.

What is Rust and why is it so popular? stackoverflow.blog Rust has been Stack Overflow’s most loved language for four years in a row, indicating that many of those who have had the opportunity to use Rust have fallen …

 
3:07 PM
If your code works and you just want someone to review it, you should post it over at Code Review instead. — Magnus Eriksson 35 secs ago
1) This post should be moved to codereview.stackexchange since it is a working code and you want improvement. 2) Its a bad pattern to have conditional behaviour in your unit tests. Define two parametrized tests if you need to have two cases. 3) Unit tests don't check for NOT throwing exceptions, this a bad approach. — Neo 42 secs ago
 
@MartinR \o
 
What is your question? You posted so much code and text. If you're wanting someone to review your code, I'd suggest codereview.stackexchange.comQBrute 45 secs ago
 
3:35 PM
If this works correctly but needs improvement, Code Review StackExchange might be the correct place to ask. — dumetrulo 31 secs ago
 
3:52 PM
0
Q: C program that reads the description of a deterministic finite automaton and builds it

Samuele B.I just got done coding this C program: Read the description of a deterministic finite automaton from standard input. The first line of input is the number of states in the automaton, n n lines follow, each one describing a state. Each line is composed of the name of the state, follo...

0
Q: Is there a way to add inheritance into this basic OOP python banking system

mp252I have been following along with a Udemy OOP basic course in Python, and one of the sections says to attempt a banking system before watching the videos. I have done what is required, however it is very basic and I know there are tweaks to be made. However I am more concerned that I did not use a...

 
4:12 PM
0
Q: Kruskal Algorithm implementation [JAVA]

terdopI'm implementing the Kruskal algorithm using a Graph class defined by me in java. My main aim is to obtain a fast execution(less than 5 seconds). This is how i've defined my graph class : Here i've implemented all my util functions to make my algorithm work properly package graph; import java.u...

0
Q: High-Level Managed Observers

Nic.StarI was thinking of adding a very high-level implementation of the event/observer pattern to my project. The implementation would manage adding and removing observers as "needed". You can use an almost DLS-like API to define when an observer should be added or removed. Here is an example of the AP...

0
Q: Angular 8 + Google Maps Autocomplete : Choice of country from an input selector

GregoryHI have a form for the user's address. In this form, I use "matGoogleMapsAutocomplete" to automatically complete the fields "street, number, postal code, city". Until then, everything works, but I'm limited to only one country, I have a drop-down list "input select->option" with the countries in m...

 
4:32 PM
0
Q: Diffusion Limited Aggregation Simulator

natter1Based on my answer to another code review question I wrote my own python script for DLA (Diffusion Limited Aggregation). The DLA algorithm task: Place seed at the center of the canvas. Release a random walker from the edge. Random walker sticks to the neighboring sites of the seed/previous poi...

 
Monking
 
You may also want to edit your code block; I can't drop it in and test it (this isn't the Code Review SE site) or give feedback on possible changes to your methodology when it's unclear how you're going about it. For example, on comments in code, comment them out (I'm assuming 'is this right?' is a comment). — Jeff Langemeier 44 secs ago
 
5:33 PM
1
Q: Sales Calculator System (with menu option)

George BradleyI was hoping somebody would be able to give me feedback on my program. For example, have I made good use of structs, vectors, and could I improve on any code-structure, perhaps a better way of doing something? I'm obviously not expecting someone to go through each part but just perhaps anything t...

 
Code Review is the best place to ask this sort of question — JonK 33 secs ago
 
LOOK, THE LATENCY FALLS EVERY TIME YOU CLAP YOUR HANDS AND SAY YOU BELIEVE
3
 
This would be better posted in codereview. Though I suggest you to post it complete. — Ricardo Diaz 37 secs ago
 
 
1 hour later…
7:14 PM
This may be a question for codereview.stackexchange.com. — jaco0646 1 min ago
 
7:44 PM
Also check out the CodeReview SE site — that other guy 28 secs ago
 
8:17 PM
0
Q: Simple Nagios Scraper - version 2

Canadian LukeVersion 1 - Beginner web scraper for Nagios Current version changes: Moved NAGIOS_DATA dictionary to separate file (and added to .gitignore) Used functions with DOCSTRINGS Removed the multiple redundant print() statements Actually read the PEP8 standards, and renamed variables to match the req...

 
9:10 PM
possible answer invalidation by ankk on question by ankk: codereview.stackexchange.com/posts/236085/revisions
 
9:25 PM
@Mast The question has been improved considerably.
 
This type of question (in which your code is already correct but may not be idiomatic) is well suited for Code Review. — Michael Myers ♦ 59 secs ago
 
9:56 PM
@MartinR I didnt use this method because of some misconceptions about (+) methods. So I took the longer route
 
10:19 PM
0
Q: Alternative way of introducing a restriction other than my descriptor approach?

Sebastian NielsenSay we have a Person class: class Person: def __init__(self): self.moods = { "happy": 5, "angry": 5, "sad": 5 } def updateStates(self, stateUpdates: {}): for mood, valChange in stateUpdates.items(): self.moods[mood]...

 
@MartinR @MartinR is that incorporating your advice ?
 
You can ask such subjective questions on codereview.stackexchange.comVandesh 29 secs ago
 

« first day (2456 days earlier)      last day (1547 days later) »