« first day (1562 days earlier)      last day (2750 days later) » 

00:00
RELOAD! There are 4249 unanswered questions (90.8539% answered)
00:12
"I have got it working..." You might want to try codereview.stackexchange.com instead. — aschepler 27 secs ago
01:04
` to increase knowledge of SO users. Will post the answer after some time.` That's not how SO works. Try codereview.stackexchange.com — Alexander 27 secs ago
01:20
@Mast That would make a good counter argument. (Sorry a friend asked me to go out last minute, otherwise I'd have responded earlier)
01:31
If you are just looking for feedback, then you should post your code here: codereview.stackexchange.com This website is for when you have problems with your code. — tima 1 min ago
0
Q: Cleaning up memory after loading Access DB into a datagrid

PhexyaaI wrote an app that pulls a MS Access DB into a DataTable and then displays it into a WPF datagrid. The dialog window has a search button which calls on a class that does the DB work. The methods in play of the search window: private void ExitBtn_Click(object sender, MouseButtonEventArgs e)...

02:04
This sort of questions are off-topic on SO. You can get a better luck on Code Review. — DYZ 10 secs ago
02:51
Try codereview.stackexchange.com. Stack Overflow is for broken code. — Claies 57 secs ago
0
Q: Complex tokenizer in C#

Michał PaszkowskiAs we have our Community Oriented Development Extravaganza, Requiring Extreme Vigor Inciting Extraordinary Winners 2017 Challenge. Finally I had some time to write a tokenizer for my own language. It is the most complex tokenizer I have written so far. The language consists of 32 keywords and sup...

03:05
possible answer invalidation by Emmie Lewis-Briggman on question by Emmie Lewis-Briggman: codereview.stackexchange.com/posts/172806/revisions
0
Q: when is [] vs {} brackets for object oriented programming?

Mudassir Faraz SharifI did research but was unable to find any input on the specifics of the difference between the operators. if there is a different than what is it between array's and object programming? I understand that array's are lists and not OOP languages... Any help would be nice

@CaptainObvious Oh a CODEREVIEW question! @EBrown
03:41
1
Q: Summing the digits of a number (subtracting the first digit if it is negative)

user146511I'm working on some practice problems using higher- order functions and while I was able to solve this problem. I can't help but think this code is ugly and not the most eloquent it could be. Is there a way to combined map and reduce is a cleaner way than I have done ? Additionally, is there any ...

 
4 hours later…
07:53
@Phrancis What's special about CODEREVIEW?
Minking.
0
Q: Sorting elements of array in ascending order

Soha Farhin PineI made this program which sorts the elements of an array in ascending order and then prints out the sorted array. #include <stdio.h> int main() { int n; scanf("%d", &n); int day[1000]; for (int i=0; i<n; i++) { scanf("%d", day[i]); } int temp, max, pos;...

08:49
0
Q: store credit program

Yash ZodeStore Credit You receive a credit C at a local store and would like to buy two items. You first walk through the store and create a list L of all available items. From this list you would like to buy two items that add up to the entire value of the credit. The solution you provide will consist of...

09:35
@CaptainObvious No code, no glory.
09:51
0
Q: Checking if a number is power of 2 or not

Egek92This is my solution in Java and I need your opinion: public class Main { /** * */ public static void main(String[] args) { Scanner in = new Scanner(System.in); int number = in.nextInt(); in.close(); if (isPowerOfTwo(number)) { System.out.println("yes"); }...

10:23
0
Q: Scraping data from tables connected to each dot on a map

ShahinI've written a script in python with selenium to scrape different table data lie within different dots on a map in a certain website. Each table is connected to each dot. The table is activated once either of the dots is clicked. However, my script is able to open that webpage, traverse the map, ...

10:49
I'm not sure you have a problem to begin with, but how about codereview.stackexchange.com for starters? — cᴏʟᴅsᴘᴇᴇᴅ just now
@cᴏʟᴅsᴘᴇᴇᴅ: this is not going to be on-topic for Codereview either. — Martijn Pieters ♦ 8 secs ago
11:00
Chrome as of 61 explicitly forbids content scripts on its default new tab page - see codereview.chromium.org/2978953002kofifus 15 secs ago
11:45
How about posting this question on CodeReview? — PeterMader 25 secs ago
11:59
0
Q: Concatenating Primes

Himanshu Ray If you like numbers, you may have been fascinated by prime numbers. Sometimes we obtain by concatenating two primes. For example, concatenating 2 and 3, we obtain the prime 23. The aim is to find all such distinct "concatenated primes" that could be obtained by concatenating primes ≤ a giv...

12:14
0
Q: Football, Data Munging

Carl FujinamiThe file football.dat contains the results from the English Premier League for 2001/2. The columns labeled ‘F’ and ‘A’ contain the total number of goals scored for and against each team in that season (so Arsenal scored 79 goals against opponents, and had 36 goals scored against them). Write a pr...

12:29
0
Q: convert the number into words from 0 to 999

LEOwhen i put 20, 30, 40, 50, 60, 70, 80, 90, 100 and the output will show me twenty zero, thirty zero, forty zero ....so on. i want to delete the zero behind twenty and forty. even i put 160 it will show me one hundred and sixty zero. how to fix this?

0
Q: Concatenating Primes

Himanshu Ray If you like numbers, you may have been fascinated by prime numbers. Sometimes we obtain by concatenating two primes.For example, concatenating 2 and 3, we obtain the prime 23.The aim is to find all such distinct "concatenated primes" that could be obtained by concatenating primes ≤ a given int...

13:00
0
Q: A simple C++ class for packing DNA strings

coderoddeIntroduction I have this small C++ program that packs a DNA string over alphabet ACGT into a bit vector, two bits per character. Code dnapack.hpp #ifndef NET_CODERODDE_DNAPACK_HPP #define NET_CODERODDE_DNAPACK_HPP #include <string> #include <vector> namespace net { namespace coderodde { nam...

0
Q: Recursive File Search

Tristan GibsonI've been working on a configurable tool that finds files by a certain specification and returns a list. I attempted to approach this in a more LINQ way and tried using appropriate design decisions, all while keeping it reasonably efficient. Here is my Finder class: public class Finder { pu...

@RubberDuck Answered your F# question - hopefully I didn't sound too elitist. ;)
@CaptainObvious Looks like a request to explain someone else's code to me.
13:23
@MartinR Agreed, applied VTC.
lol. No. Not at all.
@EBrown ^^
0
Q: Pig Latin excercise in Rust

AtmaksThe title says it all. I'm reading "The Rust Programming Language" 2nd ed. right now, and just finished the "Collections" chapter. I know there's a ton of Pig Latin code here, but I think Rust deserves a separate question. use std::io; use std::iter::FromIterator; fn main() { println!("Ente...

Can we please have a button saying 'I understand, now please take me back to the queue I was in so I can at least skip/upvote'?
In case it wasn't obvious, this happens when you try to downvote on a site where you don't have 125+ rep.
@Mast Yeah, I can add something for that.
13:32
Also, I feel it shouldn't be under OutOfVotes :-)
@Mast It's weird the way SE handles it. They don't specifically tell me what the issue was, I parse the error message.
@EBrown You could extract the issue from the message, but I reckon that would involve quite some modifications.
@Mast I do. That's done on page load.
14:17
Thx, i will try; didnt know about codereview — Kalreg 24 secs ago
0
Q: logic and usage of oop in project, javascript

KalregConsider such a code (javascript): var jsonTmp = '{ "groups": [ { "name": "G1", "status": "inactive" }, { "name": "G2", "status": "active"}, { "name": "G3", "status": "inactive" }] }' var dataTmp = JSON.parse(jsonTmp) function g(key) { this.key = key; this.name; this.status; t...

0
Q: Ploting 3D Image form a data in NumPy-array

NachiI have a data file in NumPy array, I would like to view the 3D-image. I am sharing an example, where I can view 2D image of size (100, 100), this is a slice in xy-plane at z = 0. import numpy as np from matplotlib import pyplot as plt from mpl_toolkits.mplot3d import Axes3D X, Y, Z = np.mgrid[-1...

14:50
possible answer invalidation by Michał Paszkowski on question by Michał Paszkowski: codereview.stackexchange.com/posts/172832/revisions
15:06
0
Q: How to delete items from a listview through a delete button on each item in UWP?

Anas LatiqueI'm having this issue where I make the user to add goals to a listview and each item have a grid that has two buttons a doneButtonand a deleteButtonand the description of the goal, just like a to-do list. What I want here is when the user wants to delete a goal he clicks on the goal's delete butt...

15:32
This is off topic at SO. Please repost at codereview but do format in a Minimal, Complete, and Verifiable examplemplungjan just now
@mplungjan No! Where did you get the notion Code Review accepts MCVE's? That's how Stack Overflow works, not Code Review. Please take a look at their help centre and the Guide to Code Review for Stack Overflow users before making any more recommendations. — Mast 36 secs ago
@mplungjan On top of that, OP is explicitly asking for a new functionality, something Code Review doesn't do either. — Mast 45 secs ago
Hell hath no fury like a fanatic Code Review defender.
16:08
0
Q: Command based Address book app with encryption and store facilities

A JI'm new to programming. I wrote the following code in python. It's a cmd based address book. import os from reportlab.pdfgen import canvas from cryptography.fernet import Fernet p_d_D = {} d_D = {} dd = {} file_path = os.path.join(os.path.expanduser('~'), 'Desktop', str(os.path.basename(__file_...

0
Q: Function to represent an integral in a base

nectar_moonThis function represents an integral type and represents it in a base. #include <type_traits> #include <limits> #include <array> #include <iterator> namespace detail { template <class Integral> char n_to_digit(Integral n) { static const char * digits = "0123456789abcdefghijklmnopqrstuvwxyz...

 
1 hour later…
17:10
0
Q: Python - Check website for update

jordan178I have written a program in Python that checks websites for updates (it checks in anything on the website changes) and notifies the user. The idea is downloading the webpage, stripping HTML tags off it so extract the actual text and then calculating its md5 hash, so that we know when something ch...

17:28
Monking
17:46
Request 3 more migration votes here.
make that two
0
Q: feedback on class for managing my db connections

spiralLooking for feedback for a class I'm writing to manage my db connections/queries on my site (.net core c# web api, MS Sql DB). The reason behind the class was the ever growing list of db calls and wanting to centralize not only the connection and query, but to also have it populate by objects thr...

18:12
1
Q: Voucher Management System ( A web app with ReactJS front-end)

Amr YousefI am quite new to Javascript and ReactJS. I have decided to take the ReactJS route, learn and build something relevant as well. Some feedback on how my approach can be improved is much appreciated. var React = require('react'); var ReactDom = require('react-dom'); var Catalyst = require('react-c...

0
Q: Wordpress RSS Parser

RubberDuckFollow Up to my earlier question. This is an RSS Parser intended only to parse the feed Wordpress provides (and even then, only what I actually want to display on my website). System.Linq.Xml and System.ServiceModel.Syndication are unavailable because I'm targeting .Net Core instead of the full ...

DVLR
18:39
@CaptainObvious @RubberDuck THAT is what I like to see. :) That's some damn good looking F#.
0
Q: C daemons to perpetually cache data from an external API

TimBackground My task is to create a program to continuously download utility meter data from an external API, and cache it in a MySQL database for faster access. The performance of this program is critical as it's important we get real-time data (or as close as possible), and many of the other app...

0
Q: Generic menu class for console applications

Toreno96Expanding the title: my goal (for hobby project) was to create simple, generic (customizable) and cross-platform menu class for console applications (mostly simple, text-based games). That's what I came up with: #include <functional> #include <iostream> #include <map> #include <string> class Co...

18:55
@EBrown couldn't have done it without the assist!
@RubberDuck We're all here to learn. I always try to learn something new when answering a question - I've never used yield before and it was cool to see that work. :)
6
0
Q: Codeforces problem (#711A Bus to Udayland) for finding OOs in a string array or a char 2d-array

Soha Farhin PineTask The user will enter the configuration of the bus, like this 3 OO|OX XO|XX XX|OO The number in the first line (let n) tells the number of rows. Each row has a pair of 2 seats, separated by a walkway which is indicated by a | (pipe). And a seat is represented by the characters 'X' or 'O'—t...

I've had some reasons to use it in C# before. Honestly glad you & @Hosch250 made me loop up Seq.cast<'a> though.
@RubberDuck One more thing about parenthesis. Never use them in F# in an argument call, except when calling a .NET method.
Using the parenthesis creates a tuple.
You probably know this much already, but go read the additional reading at the end of this one: checkersweblog.wordpress.com/2017/02/10/…
Now we have a new F# zombie.
A lot of F# questions here get answered, get cleaned up, then sit as a zombie because they got cleaned up so well.
4
19:15
I figured the tuple thing out last night when I saw a (XmlNode * string) -> string signature. =)
Since you guys know F# ...
Could someone enlighten me wrt. this close queue item?
Know might be a stretch for me....
it's got 4 unexplained CVs as broken
and the plain english doesn't suggest anything... but I don't know F# enough to spot the error....
> If this is correct
It is ugly for sure.
> Here is some example of that but I'm not sure this is done correctly and how to properly test it.
19:20
@RubberDuck seems like "I'm not quite sure enough it's correct yet, because I distrust myself here`
@Hosch250 should be closed as pseudocode then, and not as broken
You seem to be unsure if your code is working as expected. What kind of testing have you done? Only code that is known to be working to the best of your knowledge is on topic here. It's a frustrating experience for reviewers to spend time reviewing code only to realize later that it was broken. — RubberDuck 19 secs ago
Best I can do. Going to abstain from voting. I could go either way on it.
19:36
Monking folks!
So I'm finally in college.
3
Here's my attempt at C:
0
Q: Sorting an array of strings in C using insertion sort

AstroblemeI am a Java programmer who has C this semester. Needless to say, my writing style is heavily influenced by Java, which is probably not a great thing. I'd be grateful for a few nudges in the right direction. Here's the code: #include <stdio.h> #include <stdlib.h> #include <string.h> #define LEN 1...

I say attempt because my backbone is Java.
You are right to be unsatisfied with you current length, but because it works, this is better posted at CodeReview. — mickmackusa 34 secs ago
This question belongs on Code Review, not on Stack Overflow. — Joe C 19 secs ago
I'm voting to close this question as off-topic because it belongs to CodeReview, not SO. — lexicore 55 secs ago
19:55
0
Q: Sorting an array of strings in C using insertion sort

AstroblemeI am a Java programmer who has C this semester. Needless to say, my writing style is heavily influenced by Java, which is probably not a great thing. I'd be grateful for a few nudges in the right direction. Here's the code: #include <stdio.h> #include <stdlib.h> #include <string.h> #define LEN 1...

0
Q: My simple jQuery website returns JSON data from two different servers

JammiI'm looking advice from more experienced people about how I can improve my code. I also want to make my code object-oriented (create classes in separate .js files) but I don't how best to do it. How the program works: When the user selects a button, the data-btn attribute is checked if that att...

I was calculating values for a heater and all of a sudden my Excel looked like this:
P        2048
I          16
U         128
R           8
For a moment I forgot I was actually doing Physics and not programming.
5
Beautiful.
1
Q: Find integer pairs in an array which adds to a given sum

AKhI came up with the following solution. Is there a better way to solve this problem than the proposed? Also I used LinkedList to convey the result back to the API caller. Is there a better data structure to use? I tried using a 2 dimensional array to store the pairs, but int creation requires...

20:15
1
Q: Can I ask to review my ebuild or rpmspec file?

firegurafikuDoes the site welcome questions about writing ebuilds, rpmspecs or simular files for advanced package management? While it's relatively easy to come up with a working script, making a high quality package which satisfies current best practices and traditions of the specific distro may be incredib...

@Astrobleme congrats!
Thank you. :)
20:55
0
Q: Code beautifying for dynamic coding to create triggers (Audit Trail)

MyonaraI'm interested in all kinds of code enhancement, but I split my audit trail project for MySQL in smaller snippets. In today's snippet I want to concentrate on the ugly code I've written: a script writing a script. The generator-snippet: -- write after update trigger. INSERT INTO tmp_sql_install...

@RubberDuck Heh, well you're a hell of a lot smarter than I am so it just takes some pointers and I know you'll do great with it. All I really had to do is give you some pointers in the right direction - your natural intelligence and curiosity did the rest. Lol
64
Q: Story about humanity realizing they are in a simulation

ZonemanI'm trying to locate a story I read a couple of years ago on the internet. The story revolves around the idea that the Earth, humanity, and our entire universe are all part of a computer simulation. Because this idea has been circulating, both as fiction and nonfiction, attempting to use Google t...

That is a good story.
0
Q: Strongly connected component finding based on the guava graph library with Kosaraju

WorldSEnderI have been writing a small compiler generator for which I need to solve the strongly connected component problem. As the Guava library contains, to my knowledge, no implementation for that problem, I have decided to write my own based on Kosaraju's algorithm. For this, I have created a GraphUti...

0
Q: Using os.path.join in Python

MinäI want to reduce/shorten this part quite a lot. If you see that a method can be reduced or even erased please do not hesitate to suggest that. Any answer that rescue the code would be great. (photos, identification, testers, id) = ([], [], {}, 0) # Get the folders containing the training data f...

21:25
0
Q: Railway Oriented Programming (ROP) in C#

Ibrahim ben SalahI am not sure if there are good ROP implementations already existing in the open because I couldn't find any, actually I found one by odytrice (https://github.com/odytrice/Operation), but I think the use of Operation class to represent Func, Success result and Failure result at the same time is u...

 
1 hour later…
22:54
0
Q: Confirm regex for currency and dollar symbol

timgavinI'm allowing currency, plus letting users enter a dollar symbol (which will be stripped later). So far this seems to work, but I'd like to see if anyone can find an issue with it. Formats Allowed 10 10.00 10.50 $10 $10.00 $10.50 Here's the regex /^(\\$?($|[0-9]\d{0,2}))/


« first day (1562 days earlier)      last day (2750 days later) »