« first day (1696 days earlier)      last day (2324 days later) » 

12:00 AM
RELOAD! There are 4849 unanswered questions (90.2672% answered)
 
12:58 AM
1
Q: Python threading utilities

Coal_I've written a library with convenience functions for working with the Python threading module (specifically threading.Thread and threading.Timer). I'd appreciate it if someone could take a look at it. """ This module contains various decorators to help with common tasks involving the Python `...

 
1:47 AM
0
Q: Use a data frame of functions to calculate values using specific columns in another data frame

Bryce FrankBackground This routine is used in a package that calculates tree (as in Christmas tree) volumes for various species codes (spcd) and geographic regions. The equation forms and coefficients vary by species and region, so I have a dataframe of functions along with their respective species and reg...

 
 
1 hour later…
2:54 AM
0
Q: Maximum performance for Polard's P-1 function

Oscar SmithI am trying to find mersenne primes using python, and following the advice from https://www.mersenne.org/various/math.php, I have an intermediate step where I am using Pollard's P-1 factoring algorithm. The faster I can make this step, the higher bounds I can use, which will make my program much ...

 
def handle_book(title, list_authors, publish_year):
    insert_book_name()
    for author in list_authors:
        insert_author_name(author)
        author_id = get_author_id(author)[0]
        insert_book_author(title, author_id)
    title_id = get_title_id(title)[0]
    insert_book(title, publish_year)
What could possibly go wrong...
Argh, of-course, I should select in the get already.
Makes it a heck of a lot neater.
 
 
1 hour later…
4:22 AM
I'm voting to close this question as off-topic because the code does work and code refactor might be more suitable for Code Review. — Andrew T. 35 secs ago
 
5:00 AM
 
5:14 AM
0
Q: How to convert simple function to ES6

Hello UniverseI have a function as below written prior to ES6 was used. The code is very self explanatory. However, I find the code ugly. I want to convert this to the newer ES6 ways. It definitely can be made better Not using the better ES6 stuffs May someone please help me in making the code better? Al...

 
5:29 AM
0
Q: Need to make this utility fully dynamic, should be flexible so later we can add more enum constant & compatible to all data types

Zia/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package com.awzpact.cm.util; /** * * @author zia.khan */ interface Named { public String getName(); } ...

 
6:20 AM
0
Q: Recursive visualization of a program

YonexAs a beginner, I am facing problem in recursion. That's why I am trying to think a problem in a recursive way. I am trying to solve bellow problem. I have a specified total t and a list of n integers, I have to find all distinct sums using numbers from the list that add up to t. For example, if ...

 
6:56 AM
looks like CodeReview forum is a better place for your question — yolo sora 44 secs ago
possible answer invalidation by Gao on question by Gao: codereview.stackexchange.com/posts/183514/revisions
 
0
Q: Factory pattern along with DI using Unity container

Shreekanth GaanjiI am learning design patterns,Below is my sample code where I have implemented Factory pattern and instance creation I have delegated to Unity container Framework(DI) to build the loosely coupled system. Below is my sample code using System; using System.Collections.Generic; using System.Linq; u...

 
 
1 hour later…
8:14 AM
Merry Christmas to everybody!
2
 
8:51 AM
0
Q: Is it right way to implement logic of a simple blog using react redux react-router?

Tolya LikutinI've implemented the logic of my app, but I'm not sure whether it appropriate way or not. Task: create a react app using redux, react-router v4 which has a page with a form for adding new post and list of posts and a page with a detail view of one of the posts I've added a unique id for each p...

1
Q: c++ class to compute similarity coefficients

swdonI'm a complete beginner in c++. I wrote a class to compute similarity coefficients using Euclidean distance and Pearson coefficients on map data structure. Would like to know if it is possible to improve the code below to make it more efficient in terms of memory and time it takes to execute the ...

 
 
1 hour later…
9:58 AM
0
Q: Bundling a JS file written in comonJSish format - 1

NishantI was just going through Modular Design Patterns in JS and I came across bundlers like browserify and webpack. I was interested to see how I can flatten out a main.js written in commonJSish format that uses require to load other modules which might recursively require other modules. Here is wh...

 
10:24 AM
You should be asking such questions at codereview.stackexchange.commcsim just now
 
 
1 hour later…
11:26 AM
0
Q: My first interactive web page: Quiz App

GameatroI just learnt some web development and made this simple app. It is a quiz app. You have to click the options and after submission, result is shown. If you want to start again, you can restart with restart button. I know the code is not optimized, thats why I am asking your suggestion on improving...

 
12:00 PM
0
Q: Excel vba: program takes a long time if status bar is renewed

AnsI have a program that creates 100 000 objects of class Client, puts them into array and then goes through that array 100 times, each time assigning each Client a different random number through Rnd() function: Main sub: Sub start() Dim i As Long Dim j As Long Dim clientsColl() As...

 
you can just do a replace of spaces ' ' to ',' codereview.stackexchange.com/questions/163554/…Yassine kha 29 secs ago
 
12:33 PM
posted on December 25, 2017 by CommitStrip

Enjoy it with this great Christmas music (“O Holy Night”) : Votre navigateur ne supporte pas lélément audio element.

 
1:01 PM
@rolfl I plan on giving one or two of the Factorio T-shirts away.
 
1:13 PM
2
Q: Implemented Singly Linked List in C++

Malik BilalI have re implemented Singly Linked List based on previous review on this website. I have added Iterators in it and remove mistakes. Need suggestion! except i did not used template classes because i did not learned it yet. Thanks. SinglyList.hpp #ifndef SINGLYLIST_HPP #define SINGLYLIST_HPP c...

0
Q: Simple Tic-Tac-Toe with Minimax Algorithm

MORTALI have implemented AI to tictactoe game by using Minimax Algorithm. The game looks working okay and AI is intersecting the player moves to block him from winning the game. I would like to know if I implemented the Minimax Algorithm correctly. if so, how can I improve it further. #include <iostream

 
1:41 PM
I believe your post is more appropriate for codereview.stackexchange.comdiegoperini 33 secs ago
this question suppose to be posted in codereview codereview.stackexchange.comuser1844933 38 secs ago
 
2:29 PM
@diegoperini I doubt Code Review has enough pandas experts to judge the appropriateness of this code. — cᴏʟᴅsᴘᴇᴇᴅ 50 secs ago
 
3:18 PM
0
Q: Hiding message within an audio file with entropy detection

Animui'm currently making an application using python to hide a message in an audio file (WAV only for now). The hiding itself is done pretty quickly and without any problems, but i want to calculate the best place for it by calculating entropy. The purpose is that the higher entropy of the fragment, ...

 
3:37 PM
0
Q: Excel vba: the same code takes different time to run in different files

AnsI have a main sub that makes use of a Client class: creates an array with 100 000 Clients and loops over the array 100 times, each time setting a different random number to each Client. Sub start() Application.ScreenUpdating = False Dim i As Long Dim j As Long Dim clientsColl...

 
@miepperd I didn't correct that issue because it wasn't asked in your question. Your PHP casts everything to ints, you can change them to floats instead if you want to accept decimals. To get more general help with other problems in your code, check out StackExhange CodeReviewandrewgu 42 secs ago
 
 
1 hour later…
4:42 PM
0
Q: Excel vba: the same code becomes slow if get properties are added to a class

AnsI have a main sub that makes use of a Client class: creates an array with 100 000 Clients and loops over the array 100 times, each time setting a different random number to each Client. Sub start() Application.ScreenUpdating = False Dim i As Long Dim j As Long Dim clientsColl(...

-1
Q: Returning a float or an integer from a dictionary of dictionaries. But getting a NoneType error

Shiv_90I have a dictionary of ordered dictionaries stored through the csv module: {example_dicts: ('DictA': OrderedDict, 'DictB': OrderedDict)} These dictionaries have common columns with only some names differing. For example DictA has one column ('tripduration') while DictB has ('Duration') recording...

 
4:53 PM
Merry Monkmas everyone.
 
Merry monkings to everyone tooo
 
5:15 PM
possible answer invalidation by DNK on question by DNK: codereview.stackexchange.com/posts/183307/revisions
 
0
Q: Is it the simplest plugin system with autoloading?

stckvrwI know there are many posts about different plugin or hook systems, but I would like to know everything what you think about my system. It's the main index.php: <?php define('version', '1.0'); class mainClass { public static $content; public static $added = []; public static functio...

 
6:15 PM
Merry Christmas, everyone.
2
 
6:40 PM
0
Q: Harckerrank Attribute Parser

WooWapDaBugThis code is to solve a Hackerrank problem called "Attribute Parser". It's my first time dealing with regex in cpp and I wonder if I managed to be expressive enought to tell with the code The HRML explanation from Hackerrank: We have defined our own markup language HRML. In HRML, each eleme...

 
It seems obvious that if you have unique ids you should store them in an object keyed to id. I’m not sure why you are worrying about multiple threads in a Node app, though. This may be a better question for codereview.stackexchange.com if you just want advice about the approach. — Mark_M 47 secs ago
 
7:17 PM
0
Q: Single Page App - Browser Storage API Design

lamelemonI'm working on building a Browser storage handler for my single page application. The idea is that you make an API call and the API calls the storage handler which either returns the local/session storage or if it doesn't exist it calls the actual web service. The StorageHandler uses a Proxy to...

 
 
7:54 PM
0
Q: What is the space complexity of this function?

Rocky SinghI'm given two sorted arrays, arr1 and arr2. They can either be of the same length or arr2 will be longer than arr1. I implemented a method findDuplicates that returns an array of all numbers that are both in arr1 and arr2. Note that the output array should be sorted in an ascending order. I know...

 
I understand the difference between code review and the web annotations. However is there any way to list or track the web annotations? For example if I make a comment and put it as pending how can I find that in the future? — SheldonH 50 secs ago
Is your solution not working? Is there a real problem with your code? Code-Reviews fit best on codereview.stackexchange.com... — ventiseis 47 secs ago
 
8:53 PM
0
Q: Items derived from one function are getting printed within another for loop in another function

MithuI have written some code in python to scrape some items from a webpage. There is a link (titling see more) attach to each container. If I click on that link I can reach a certain page where all the information are available. It is quite convenient to track the see more link and parse all document...

 
 
1 hour later…
9:56 PM
-1
Q: Sort multidimensional array based of the difference in the value, if value is same sort on first column

Sandesh WaniSort multidimensional array based of the difference in the value, if value is same sort on first column. Constrains : No of rows can be any but fixed no of column ie 2. Example: int arr[][] = new int[5][2] [0] [1] [0] 0 6 [1] 0 7 [2] 4 5 [3] 2 3 [4] 0 1 Final Output: ...

 
10:11 PM
0
Q: Updating WPF image from camera frame grabber thread

geometrikalI have created a WPF application in .NET 4.6.1. to display video from the frame grabbing event for a machine vision camera. In XAML there is an image control bound to a WriteableBitmap <Image x:Name="CameraImage" Grid.Column="1" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Source="...

0
Q: Small Text Game Using Python

Axel1212I just finished making(well, trying to make one) a small text adventure in Python and I was wondering what I could have improved with it. Please note that this is my first time using Python. I pretty much had to keep Google open the whole time. """ Created on Sat Dec 23 23:57:38 2017 """ import ...

 

« first day (1696 days earlier)      last day (2324 days later) »