« first day (2821 days earlier)      last day (1189 days later) » 

12:00 AM
RELOAD! There are 7282 unanswered questions (89.6336% answered)
 
 
2 hours later…
2:02 AM
0
Q: Parallel map in Rust

cylde-frogA parallel map written in Rust. I am new to Rust and wondering if there is things that could be done better or more efficiently. use crossbeam_channel::unbounded; use std::{thread, time}; fn parallel_map<T, U, F>(mut input_vec: Vec<T>, num_threads: usize, f: F) -> Vec<U> where F: FnOnce(T) ->...

 
2:22 AM
Welcome to SO! Please take the tour and read How to Ask. Questions about improving existing code are better suited to Code Review, but check out their How to ask page first. — wjandrea 8 secs ago
 
3:09 AM
 
 
3 hours later…
5:51 AM
0
Q: Array-Sum Operation hackkerrank

17159I'm trying to solve this problem in Hackerrank. I had a solution as below but it got failure. Could anyone help to tell me what's wrong I did :( Summary of problem: You have an identity permutation of integers as an array initially. An identity permutation of [1-N] integers. In this task, you h...

 
 
1 hour later…
7:16 AM
Are you facing any issue? Every problem has multiple solutions... the best one is the one which works for your without any side effects... if you are facing any issues then you need to describe it here... otherwise it looks like you are asking here for a design/code review.. — Chetan Ranpariya 5 secs ago
 
7:33 AM
0
Q: GUID Usage Suggestion

Mahmed AmerI am building an education website where: A student (I will call him/her a user) goes to an "educational center" then pay money for a "Attempt code" (From 5 to 8 digits "Unique") User opens the website and then enter the "Attempt code" to get a "Code" Generating Attempt User is then able to gene...

 
 
1 hour later…
8:49 AM
0
Q: Request for help to speed up batch program for 17,000 TXT files

JohnI have over 17,000 pages that have been scanned (for a local history archive) which I have OCRed using Tesseract to individual TXT files. I want to be able to search/locate every page containing a search word of more than 3, lower case letters. So for each TXT file I need to: Delete all rubbish f...

 
Monking
 
 
3 hours later…
11:22 AM
0
Q: Gradient of regularizer wrt to weights in L2 regularization

YugenswitchIn the empirical risk minimization formula that I am using for my neural net, the formula for updating the weights looks as follows: Delta = (-Gradient of weight) - (lambda * gradient of regularizer) Weight = Weight + alpha * Delta In the source that I'm referencing, the gradient of the l2 regul...

 
Monking
 
 
1 hour later…
12:25 PM
Monking
 
12:37 PM
You can post your current solution on CodeReview. Right now it looks like you are asking to have someone do your homework. — Henk Holterman 9 secs ago
 
1:09 PM
Could use some guidance here, does this question belong on CR or SO?
 
1:29 PM
0
Q: Using pytest fixtures for the expected answers to a test?

Ian CarpenterI want to test a number of different functions I have written to solve the Fizzbuzz challenge and would like to know what is the best way to check the result? Each function returns a list of the answers and I want to check the list is correct. One of the functions is shown below def fizz_buzz_usi...

 
2:14 PM
Warm welcome to the people arguing over this in code review — Artur Tagisow 38 secs ago
 
2:45 PM
0
Q: Plotting realtime data comming from sensor in matplotlib, gtk3, python

Michal P.I'm trying to plot some data that are comming from sensor(not scope of this post). I have a window created in glade and everything on the background just works. The data are comming 2times per second, there could a delay. So the update_graph(x,y,z) is to to be called. Once it's called I just want...

 
3:24 PM
I tried to find a but report for this but nothing. Maybe not copying is for performance reasons? Using a TextureManager seems interesting, Here an interesting "thread" (not too short)Wolf 1 min ago
 
3:36 PM
0
Q: Error handler library refactory

Francisco NúñezI have this Library to control errors; I would like if you can evaluate it and make a review of the code: I am looking for external people to do functional tests, although everything works for me correctly. I am also open to hear opinions on any type of improvement that can be implemented as long...

0
Q: C# Password Security Login System with SQLite

EvorageI want to start by just mentioning I'm a semi-beginner at C# and cyber security so any feedback is appreciated :) What I think I need reviewing is the SQLite queries and maybe the hashing functions I'm making a password manager project (sorry in advance for wall of code): The supporting functions...

 
 
1 hour later…
4:52 PM
0
Q: Optimize and beautify hybrid quicksort-Insertion for multi-key 2 dimension array VBA

porkalocaHi! This is just for fun, the speed of this algorithm is surely much more than what I need, but it's really engaging and stimulating try to spot out every possible improvement. And it also helps to understand the "weight" and power of the instruments of the language. Below the code of the class. ...

 
5:43 PM
0
Q: Cat clone with unit tests

User319This is a clone of the cat utility. The goal of this exercise was to get comfortable doing basic tasks in a new language, figure out how to set up testing, etc. So I'm really looking for feedback on writing more idiomatic Rust, if there are better ways to approach things, etc. In particular, my T...

 
6:09 PM
0
Q: std::vector Allocator-Aware Implementation [Beginner]

SomeoneWithPassionI've just finally finished implementing std::vector. I'm currently re-implementing whatever I can in the hope to learn more of how data structures works. I tried to respect all requirements, but I probably missed a lot (or made mistakes). At first I thought implementing std::vector would be somew...

 
6:41 PM
If your code is working and you are looking for advice to improve it, it might be a better fit for codereview.stackexchange.comThierry Lathuille 21 secs ago
 
6:55 PM
possible answer invalidation by lorem.ipsum on question by MoonReddit: codereview.stackexchange.com/posts/254882/revisions
 
@Duga Rolled back.
 
0
Q: How to Replace Connect Four Code with a For Loop

VixI have a Connect Four game with a board that I made with a bunch of print functions, which is incredibly inefficient. Here it is: print(" 0 1 2 3 4 5 6") print(" " + board[0][0] + " | " + board[0][1] + " | " + board[0][2] + " | " + board[0][3] + " | " + board[0][ 4...

 
7:21 PM
If you are looking for someone to review your code please use codereview.stackexchange.comRachid O 34 secs ago
 
7:51 PM
0
Q: Project Euler Problem #85 in Scheme (Guile)

Berken TekinI've decided to revitalize my Scheme knowledge coming from SICP, so I've started using Scheme for Project Euler problems I've already solved in Python. However, this proved to be difficult. It seems that I've become too accustomed to the "straightforwardness" of Python, so I can't wrap my head ar...

 
8:27 PM
if you are writing an entry for the Python Obfuscation Contest keep on going but if you need this code reviewed before committing it does not adhere to readable code — rioV8 30 secs ago
 
9:14 PM
This kind of questions is better asked at Code ReviewJens 52 secs ago
Thanks, I will post my code in Code Review — teja sri 58 secs ago
 
9:32 PM
0
Q: Read value from config and return function

Rayn DI’ve the following function which should be run in production I read some config If valid add the runner otherwise just return, Is there a cleaner/better way to do it in go? https://play.golang.org/p/QcU9YHDXo36 func (z *zmp) Add(val string, runner Runner) { vmap := viper.GetStringMap(val) ...

 
9:58 PM
0
Q: Cyclic Permutations Calculation

halcyon44I have come across a problem on cyclic permutations. It is about swapping numbers around. It starts out with input N < 100,000 which makes the first N natural numbers as orders: 1 2 3 ... N-1 N Then we get the next input K < 200,000 as the period Next N input lines are the swaps: For example, the...

 
10:38 PM
Looks like you are asking to review your running code. If so you should ask this question at Code ReviewJens 26 secs ago
Ask questions about reviewing code at Code ReviewJens 42 secs ago
 
11:14 PM
0
Q: C++ matrix class follow up

Pel de PindaThis is a matrix class with addition and multiplication. I tried incorporating all the helpful advice I got on my previous attempt C++ matrix class , specifically using std::vector for memory management, overloading operators, adding error messages and adhering to the rule of 5. #include <iostream>...

-1
Q: need some guidance for better coding practice

teja sriGiven a int optimumMemory and int[] array with list of available memories find the pair of indexes of memories whose sum of the values will be equal to the optimumMemory? If there exists more than one such pair whose sum of values are equal to the optimumMemory then filter out the indexes for the...

0
Q: How to Let User Choose Number of Rows and Columns in Connect Four Game

VixI've completed a Connect 4 game but I want the user to be able to choose the number of rows and columns. Could somebody help me with that? Here is my code: https://paste.pythondiscord.com/iwitecuxum.py Thank you so much! The board can be found under main() and display_board(board) def main(): ""

 

« first day (2821 days earlier)      last day (1189 days later) »