« first day (1592 days earlier)      last day (2411 days later) » 

12:00 AM
RELOAD! There are 4335 unanswered questions (90.8306% answered)
 
12:18 AM
I'm voting to close this question as off-topic because it should be on codereview.stackexchange.comuser2718281 24 secs ago
 
12:36 AM
0
Q: Python PriorityQueue Sorting

googDuplexI'm new to Python and I'm playing around with the PriorityQueue. My code is very strange and I was wondering if someone who know's a bit more about Python could explain. It basically takes a list of intervals, dumps it into a PriorityQueue, which sorts by start times, and then puts it back into ...

 
12:50 AM
0
Q: Scale SVG section

JeffI’m working on a page that has four separate sections in a 2×2 grid, each of which is an inline SVG composed of several entities (s, s, s, and . The goal is to zoom in on any of these four sections when the user clicks on it. Strangely, I can get the sections to zoom if I assign a hover state in ...

 
1:33 AM
0
Q: PHP Routing with MVC Structure

nickI'm trying to do a simple CMS with PHP from scratch using MVC structure. Yesterday I posted this: PHP Login System with persistent login Which is a login system using PHP and it works but it has a handful of problems regarding the OOP aspects of it. So now this is kind of the version 2. It doe...

 
2:19 AM
0
Q: Collatz Conjecture (c++)

jxshuI am new to C++ and this is my first program. The objective of this program is to fully complete the sequence called the Collatz conjecture. It concerns a sequence defined as follows: start with any positive integer n. Then each term is obtained from the previous term as follows: if the previ...

0
Q: Joining strings to form a url

ThanassisI have to construct a url string from smaller substrings. I'll usually have a resource url, an endpoint, a query, but you can imagine even more parts in creating a full url. If for example, I have this resource url: http://foo.com, this endpoint: bar/v1, and this query: q?var1=33,var2='abc', I ...

0
Q: Arrow key input to change selected row and column in a grid of html elements

Rather NotsayBelow is the working code but it can surely be simplified with some sort of changeCol() and changeRow() functions, or perhaps a single function? $(document).ready(function(e){ let keys = {}; let selRow = 0; let selCol = 0; //set initial highlits $('[data-x="0"]').addClass('...

 
There can be no real answer to this question. You're basically looking for a code review, and that's not what Stack Overflow is for. — Brian Gottier 20 secs ago
 
2:50 AM
0
Q: Make picturebox control always on-top and transparent over all controls

AnthonyI'm writing a Winforms application for my company's customer. In one of the forms, there are two picturebox controls. What I am required to do are: They should always be on top of all other controls. They should be perfectly transparent so that if there is any control located under them, user s...

0
Q: Hashmap: refactoring java (hackerrank ransom note)

user3551523the question is like this: A kidnapper wrote a ransom note but is worried it will be traced back to him. He found a magazine and wants to know if he can cut out whole words from it and use them to create an untraceable replica of his ransom note. The words in his note are case-sensitive and h...

 
3:07 AM
0
Q: String of numbers to Integers (without using .to_i)

NathanMy exercise was to take a string of numbers, such as "1234" and return them as an integer 1234. However, I wasn't allowed to use #to_i, #to_f, Integer, etc. def convert(int) x = 0 array = int.split('') array.each.with_index do |y, i| x = (x + (y.hex)) x = x * 10 unless i == array.l...

 
possible answer invalidation by Thanassis on question by Thanassis: codereview.stackexchange.com/posts/175421/revisions
 
3:25 AM
possible answer invalidation by Jamal on question by Thanassis: codereview.stackexchange.com/posts/175421/revisions
 
3:41 AM
0
Q: Divisions using Arraylists

Michelle Exercise: Using Arraylists create a program that makes divisions between two very large numbers (numbers greater than 10 digits). I did it (the code works), but could my code be improved? public class Main { static void division(List<Integer> lista, List<Integer> listb) { List<...

-1
Q: Computing divisibility and multiplication

John Jerome PerezPlease check my Java program to see if I use the global variables, nested loops and two functions with parameters correctly. I also need suggestions to improve my program. import java.util.*; public class javaProgram { public static int loopCount = 0; static Scanner scanner = new Scanne...

 
4:15 AM
-1
Q: How to determine a 1ms delay in C

CocovanillaI am completely new to programming. I am trying to write a code that will give a 1ms delay, using a loop. I have been researching on the internet and found the following: main() { int c = 1, d = 1; for ( c = 1 ; c <= 32767 ; c++ ) for ( d = 1 ; d <= 32767 ; d++ ) {} return 0; } ...

 
4:30 AM
I'm voting to close this question as off-topic because the code is working. This question is better asked on the Code Review Stack Exchange. — AJNeufeld 41 secs ago
 
Monking
 
5:14 AM
I second Phil. If you have a working code and you are seeking advice regarding best practices, I suggest Code Review. — Gerardo Furtado 18 secs ago
 
5:37 AM
1
Q: Writing JS style code

SamMy background is primarily in C#. Though, I've gotten comfortable with JavaScript, I feel that stylewise my JS code looks more like C# code. Does the following code's style conform to "standard JS style"? processArray = (myArray) => { if(typeof myArray === "undefined" || myArray == null || ...

 
6:10 AM
0
Q: Javascript typehead using debounce

Rahul AroraThis is the code I wrote of making a javascript typeahead which displays cities. It will be great if you can suggest some improvements on the code quality. JS 'use strict'; var data = ['alabama','alaska', 'arizona','arkansas','california', 'colorado', 'connecticut', 'delaware']; /** * vari...

 
6:21 AM
you should ask in code reviewJohn Joe 49 secs ago
I'm voting to close this question as off-topic because this question belongs on codereview.stackexchange.com. — Seelenvirtuose 55 secs ago
 
7:01 AM
0
Q: Permutation of objects, increase maximum limit

RMad9248I am using this function to find all permutation of objects of a given length. However, right now, the maximum length I can reach before it throws an "Out of memory exception" is 9 (also, it gets too slow from 7 onwards) IEnumerable<IEnumerable<T>> PermutationOfObjects<T>(IEnumerable<T> objects,...

 
What this line do Boolean(getText($('td:eq(1)', e))) ?
 
possible answer invalidation by 200_success on question by Pranit Kothari: codereview.stackexchange.com/posts/175441/revisions
 
7:16 AM
1
Q: Topological sort of a graph

Pranit KothariPlease refer following graph. Please review following code for topological sort. I can sense one odd thing in my code, TS() is calling TSUtil(), still I had to write Visited.emplace(n.first); and Sorted.emplace(n.first); in TS(). Please suggest if I could handle it better. test() method ...

 
7:37 AM
This belongs on the codereview exchange I think: codereview.stackexchange.comkabanus 44 secs ago
 
8:18 AM
Monking
and also: I'm right back to the conference I'm currently attending :)
 
8:32 AM
1
Q: Python webscraping for lists of company names and details using BeautifulSoup

JamesI just started learning Python and made a script that scrapes a corporate directory https://www.sccci.org.sg/en/directory/corporate/members So far it gets all the company names and their details under one category page (although i do intend on making it automatically get the details of the othe...

 
8:47 AM
0
Q: Finding an increasing sequence from a given array in a time-efficient manner in Python

Sreedhar DanturthiProblem Statement: Given a sequence of integers as an array, we have to determine whether it is possible to obtain a strictly increasing sequence by removing no more than one element from the array. Example For sequence = [1, 3, 2, 1], the output should be almostIncreasingSequence(sequence) = f...

 
I'm voting to close this question as off-topic because it should be posted on codereview.stackexchange.comMarcin Orlowski 1 min ago
 
9:06 AM
0
Q: Click n times on image to match with random number n

Asfath AhamedChallenge Create a page with An element for number, An image An unordered list tag for list of images A 'Check result' button A text element to show result Generate random number and put it in (i) On click the image it add an li with the image inside UL tag On click check result button,...

0
Q: Is this variant implementation good?

yer-boiI've been fiddling with templates and compile time stuff i implemented a variant container and wanted some opinions and recommendations this is just a learning exercise, a couple template classes not included here are tl_type_at which gives the type in a typelist at a given index; and tl_index_of...

0
Q: My first nontrivial control in the Angular 2+ framework - image feature selection

Minor ThreatI was needing something like this to select multiple features at my source images to train my machine learning algorithms. However, this jQuery control behave erratically on input property change. I haven't been able to bind it properly without making fragile spaghetti of change listeners. After ...

 
9:55 AM
possible answer invalidation by RMad9248 on question by RMad9248: codereview.stackexchange.com/posts/175437/revisions
 
10:22 AM
 
0
Q: Enumerating RCData resources from the EXE file which has been launched

VlastimilI am running Delphi XE6. I recently integrated all of my read-only language INI files into the executables. As a consequence, I need to enumerate RCData resources (and then simply filter out the languages). I stumbled across solution, which I lightly changed into this form: function EnumRCDat...

 
11:03 AM
0
Q: Pull out text within specific divs on a webpage

SJCI am looking for some guidance and feedback on my first golang program. The language is very new to me and its been a long while since I have written anything close to C. Below is a simple program that takes a url and looks for divs within the page containing a specific class. Once found I read ...

 
11:25 AM
I believe that you question should be asked on codereview.stackexchange.comummahusla 52 secs ago
 
11:38 AM
0
Q: timepicker component in reactjs

milanI have developed a simple timepicker component. The functionality of this component is a) Show time in both 12 hour format and 24 hour format b) User can select hour, minutes, am, pm c) When sending the time to the server, the time should be in 24 hour format For now the bug I have seen ...

1
Q: C# - Entity Framework + Repository pattern + Unit of work pattern

hyperNAfter hours spent on reading various articles about correct way to implement Repository patter & UoW patters I finally think that I have managed to create (hopefully good) implementation. The worst thing is, not that it is too complicated, or anything like that, but it seems that there is no gen...

0
Q: 3D N-body brute force simulation

Brandyi am trying to run a 3D N-body simulation. For the whole day i have been trying to get this code to work but i am getting two errors: 1)undefined reference to Galaxy::resetForce()' 2)undefined reference toGalaxy::addForce(Galaxy) error: ld returned 1 exit status| #include <iostream> #include <...

 
11:58 AM
If you're looking for a better answer, then shouldn't this be posted on codereview.stackexchange.com? — jumpingcode 37 secs ago
 
12:16 PM
Should be on codereview.stackexchange.com. — Heinzi 9 secs ago
 
12:42 PM
0
Q: Simple c++ program that calculates the measures of a sphere

Fix3rI got another home work from school and would like to see if I am on the right path to learning c++. We have to do the calculation of the measures of a sphere. I did it two ways: 1 - just calculating everything at the main 2 - using a function #include "stdafx.h" #include "iostream" #include <...

0
Q: Compare two Sheets for matching data and group them on another sheet

MoacirI have two sheets with data that comes from system reports (Razão and Kardex) and a sheet with parameters (Operações). The first thing this code do (except defining some variables) is to group the parameters as "Out" or "In" (opsaida or opentrada) inside two distinct collections. Then, for each ...

 
12:55 PM
possible answer invalidation by RMad9248 on question by RMad9248: codereview.stackexchange.com/posts/175437/revisions
 
0
Q: WP/PHP Form validation and sanitization

ElianI'm kinda new to form sanitization and validation. If someone could look at my code and tell me where i could do things better, i'd appreciate it a lot. Here's my form: <div class="inquire-form"> <form action="<?php echo esc_url( admin_url('admin-post.php') ); ?>" method="post"> <la...

 
1:11 PM
I'm voting to close this question as off-topic because If the code actually works then this question would be better off on codereview.stackexchange.comNkosi 56 secs ago
I'm voting to close this question as off-topic because it belongs on the CodeReview site. — Dmitry 22 secs ago
 
1:27 PM
0
Q: Optimize a document text filter? C#

Paula DanielaI have a school project where i have to develop a text filter, this means that a have a document and i want to extract the line that contains the word the user wants, that is generally more than one, and it stores the filtered text in a different file. So actually i achieved that already by nest...

 
1:54 PM
If this is working code, maybe it's a better fit for Code Review? — glibdud 56 secs ago
 
0
Q: Convert the string in given format

user148675Convert the string: "(id,created,employee(id,firstname,employeeType(id), lastname),location)" to the following output id created employee - id - firstname - employeeType -- id - lastname location Please provide a solution with out using the regular expressions. The solution I came up with is giv...

0
Q: Add 256 based byte array Recursively - Follow up

Yawar MurtazaThis is a follow up request from Base 256 array addition Recursively - Follow up Due to additional requirements, I had to change the method. Arrays first and second are identical in length, the calling code (below) is unchangeable. private byte[] AddRecursive(byte[] first, byte[] second, int i...

 
2:36 PM
0
Q: VB.Net OOP - Is it correct with VB OOP (Am I doing it right)

FreeCodebeing VB developer for couple of years but using functional programming, and just started out in VB OOP few days ago. I'm writing a small calculator app in order to understand VB. Net OOP and the program is working perfect the way I've done it following books, and I just want to know from you gu...

 
2:55 PM
0
Q: x64 Assembly zeroing an array (8 bytes at a time)

signe kattIs there a better way of implementing this other than using simd instructions? What is the best way of dealing with arrays not divicible by 8, as in the code where if there are less than 8 bytes left to zero they just get zeroed 1 by 1 or is it faster to check how many bytes there are left and t...

 
3:14 PM
@CaptainObvious Shot in the face, twice.
 
possible answer invalidation by Bob Horn on question by Bob Horn: codereview.stackexchange.com/posts/175233/revisions
This question would be more of a topic for codereview.stackexchange.comError - Syntactical Remorse 5 secs ago
 
0
Q: Linked list in Python which gets values from keyboard

P-boxWhat do you think about my implementation of linked list, which gets values from keyboard? I implemented three basic functions: print, insert and size. class Node: def __init__(self): self.data = None self.next = None class LinkedList: def __init__(...

 
3:30 PM
posted on September 12, 2017 by CommitStrip

2
 
3:40 PM
0
Q: Python CLI for download/updating large UniProt protein databases

James DraperBackground This script is can be used as a command line interface (CLI) or a sub-module in another program to download the latest UniProt proteome for a given taxon. Files are downloaded to the same directory as the script. Code #!/usr/bin/env python "UniProt Proteome Updater" # Copyright Jam...

 
4:03 PM
Belongs to codereview.stackexchange.com — The_Black_Smurf 34 secs ago
 
Monking
 
1
Q: 355 - The Bases Are Loaded (math numbers conversion)

user148687Recently I found this task, which is to convert numbers between arbitrary bases. My code is working fine, but time limit exceeded. #include <cstring> #include <cstdio> int broj[50], n; char uzorak[] = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', '...

 
4:30 PM
0
Q: Limit Drive Starts with Function Block Diagram

Will VI have a drive (modulating fan) which needs to be interlocked and prevented from starting. The requirement is that: The drive is limited to 3 starts per hour with a minimum of 10 minutes between starts. I am programming using function blocks diagrams. Some information to aid in your underst...

 
Monking
 
@Mast Do you understand that Function Block Diagram question^^?
 
4:45 PM
possible answer invalidation by Dalek on question by Dalek: codereview.stackexchange.com/posts/174814/revisions
 
@DanPantry That's an april fools, right? *checks date* Right.
Shame. That would have been a product I would recommend to my students.
 
5:03 PM
1
Q: Unity. Need help in optimizing and making code smaller

NickI've already posted this question on GameDev, but as people have recommended, I will post it here. I will go straight to the point. I am making a tank game. I have database on server where I store information about Tank itself, Hulls, Turrets, and Guns. When the server gets "Hull" request it ...

 
5:18 PM
@EricLippert we've had this exact discussion before: codereview.stackexchange.com/q/164919/140484 . For quick shuffling, choosing between Random and a NewGuid() should be arbitrary, and on current windows OS, NewGuid() actually uses a CSPRNG unlike Random. If randomness is a critical feature of the app, then neither Random or Guid.NewGuid() is appropriate. — BurnsBA 47 secs ago
 
@Zeta You ahve students?
 
@skiwi Had students as programming TA.
 
Ah okay, interesting
I suppose I could've also made the world a better place by being a TA a few years ago, except I was making brainfuck compilers
 
5:35 PM
possible answer invalidation by Dalek on question by Dalek: codereview.stackexchange.com/posts/174814/revisions
 
@Duga It's fine (removed bug that wasn't mentioned in the answer).
@Duga Oh. I'm not so sure about the Test.py edit.
@skiwi At least you've learned something. I learned so many ways how to not write C (or C++).
 
@Zeta I'm afraid I'm learning that right now
Legacy C++ without any use of the standard library, yay
 
Ah, legacy C++.
Also called Cthulhu++, I guess.
 
And when I look at modern C++ it looks a lot like Rust, except Rust solved the issues in its language, and with C++ you are looking at ownership, explicit moves, etc.
 
*sigh* Pattern matching and ownership.
And sane macros.
 
5:47 PM
If only some companies would actually use it..
 
Mozilla doesn't count, right?
 
It counts, but not on a personal level
And I doubt writing Rust for fun is going to work, because it's just a back-end language and a quite low-level one at that
Not really suitable with simple projects
 
My issue with Rust is the missing specification and long-term-stability.
 
It wouldn't surprise me if there's not a single company in The Netherlands that uses Rust
I don't know if it has left its beta phase yet?
 
@skiwi There's piston and other crates.
 
5:51 PM
@skiwi Probably a bunch here state-side that use it.
 
I think the correctness pays off mostly in large applications
 
@skiwi It has. It's version 1.20. It's just that the reference is in the compiler itself, and it continues to be a moving target. If you try to write your own Rust compiler you will always be a step behind. Great for innovation, though, but hard to check for soundness.
 
Sounds like still needs to mature a bit then
Tomorrow will be a fun day at work.. For the past two days I've been rewriting our web communication, which involves the server and a DLL that's loaded in IIS, and that doesn't count at least a day to get a feeling for how everything works, etc.
I haven't been able to test anything in isolation for 16 hours :D
I'm going to be worried if everything works on the first try
 
6:55 PM
0
Q: Simple object oriented console calculator

AgnieszkaI'd like to learn OOP. Could someone check my code and tell me how to improve it? package com.company; import java.util.InputMismatchException; import java.util.Scanner; public class CalculatorApp { private static Scanner scanner = new Scanner(System.in); public static void main(Stri...

 
7:40 PM
In that case it seems more relevant for the Code Review SE. codereview.stackexchange.comnbokmans 52 secs ago
 
8:08 PM
I do see what you're saying. With the TFS though they can look at the suggested changes without having to get the code checked in. Ultimately, I am wanting to tie the review with the check in. but do it from the code review side of things once it is approved. Instead of checking in immediately because I may have to rewrite the entire code base perhaps based on code review suggestions. — Max Pringle 14 secs ago
 
8:30 PM
0
Q: How to avoid sigkill error 9?

Furqan HashimI am trying to build an algorithm which first builds a power set of around 100 symbols excluding null set and repeated elements. Then for each item in the list of power set it reads data file and evaluates the Sharpe Ratio (Return/Risk). Results are then appended to a list and at last the program...

0
Q: Generating valid combinations of sets in Prolog

ScriptimFollowing rules are defined: foo(a,[b],[]). foo(b,[],[]). foo(c,[],[d]). foo(d,[],[]). The goal is to get a list of lists, that contains all of those atoms (a, b, c and d) without duplicates, e. g. [[a, b, c],[d]]. The sublists in this list have to be "valid", that means that each element in ...

 
8:47 PM
This is off topic for SO, try out codereview.stackexchange.com instead. — pingul 9 secs ago
 
9:01 PM
0
Q: Python Image Encryption Security Analysis

back_seat_driverI'm currently seeking someone to review the source code for an image encryption program in python 2.7. The code is complete and should run provided you have installed the correct packages. For this project I used Anaconda 2 as it had scipy which was convenient for its write access. I've spent so...

0
Q: is my string finder function OK?

trapaholicsremixThis function finds a certain string within a string. I feel like my function is too messy.... I'm new to C memory functions, is there any shortcuts I can take to make this function shorter? is this implementation effective? thank you in advance. bool strfound(char * find, char * name) { int j =...

 
9:13 PM
What I am asking would not be a work around. Ultimately it would tie the code review to the check in, but would only check in once the code review is complete. Once complete, I could check in from the code review tab is what I am wanting. — Max Pringle 30 secs ago
 
9:30 PM
I'm voting to close this question as off-topic because if is more suited to Code Review SE. — quetzalcoatl 27 secs ago
 
9:52 PM
I agree this is probably a better fit for CodeReview. — Michael0x2a 37 secs ago
 
10:32 PM
Sounds like you need serious code review. I would go bananas if something is called response or Webservice1. Who named these things? Might as well just use x, y, z.l This is a clear indication that you have no coding standards as you clearly show no naming convention. This is the pit you fall into by not having them defined. — Namphibian 45 secs ago
 
11:21 PM
might try posting on code review? — Forward Ed just now
 

« first day (1592 days earlier)      last day (2411 days later) »