# All Questions

5 views

### SQLite app for local storage

When I make an app using SQLite for local storage I've settled into a nice routine; create a contract class and a extended BaseColumns class to hold column names ...
5 views

### Genetic Drift Simulator - Follow Up

This question is a follow-up of a previous question of mine: Genetic Drift Simulator. Following the advice given in the last question, and some more general improvements, the code has been slimmed ...
9 views

### Generating 3 combinations in Python

I have been experimenting around with generating all the n-combinations of an array. This code quickly generates all $\text{k-combinations}$ of a given array. I am testing my own implementation ...
15 views

### Program based on a physics concept

I am a beginner and I wanted to make programs that would help me while I learnt Java. I made a program to help me in my assignments. Any suggetions? Main method ...
17 views

### Finding clients in a 100 km circle

I needed a node app that: reads a list in text file format from URL parses the rows on the list. (fields: id, name, longitude, latitude) finds names of the people who live maximum 100 kms away from ...
22 views

### Getting funky with Pi

Push a button and an LED lights up1 and sends a signal to another computer that plays a song. First project on the Raspberry pi, really simple but definitely fun and educational to implement. Also, ...
11 views

### Python3 Alarm Function

I'm trying to create an alarm function with Python3. The below code does work but it doesn't seem like this is the most optimal way of achieving something like this. Is there a more pythonic way? ...
11 views

### Return inside switch best practice (JS) [on hold]

Let's say the function below expects an attribute. It goes through the switch if it has one of the values in the switch everything is fine. If it goes to default it returns false which in this case ...
9 views

### What is wrong with this code to interpolate colours? [on hold]

I have written a module to choose a colour on a gradient between two other colours. The purpose is to aid in setting up styles for my trading platform. I don't have enough reputation to post all the ...
27 views

### Max and Min in array using minimum comparisons

Is this the most robust and fastest way for finding the min and max out of an array without using STL functions? How can I improve it? ...
16 views

### computational performance, Microsoft Visual c# vs Intel® Visual FORTRAN [on hold]

i am programming in c#, but recently i was trying to check performance, taking c# to it's limits via unsafe and parallelism..etc'. then i have discovered that for things like low level computations ...
17 views

### The Handy-Dandy Apocalypse Assistant

Code Review is running rampant with an infection. A zombie infection. Everywhere posts are becoming rapidly mutated into slobbering, green freaks of nature. But the citizens of Code Review are ...
21 views

### The Yahtzee Game

I am designing two methods to be used in a Java implementation of Yahtzee. For those not familiar with the game: Players take turns rolling dice and acquire points based on the face up values ...
33 views

### Tic-Tac-Toe Game (Java)

This program runs the game tic-tac-toe within the console. The players, X and O, take turns placing their character onto the 3x3 grid. When a player successfully makes 3 in a row, either vertically, ...
282 views

### Searching for bad Minecraft questions on Gaming.SE

To preface this post a little bit, I'll explain a little bit of the "backstory" here. On the Stack Exchange site, Gaming.SE, also known as Arqade, often has a large influx of bad questions about the ...
33 views

### Dealing with a class that has organically grown too large

Disclaimer: This is live, production code for my hobby project: LSML (GitHub). Due to the size of the code I'm unable to include everything in this review. The application is a tool for configuring ...
27 views

### Merging files in Bash

I had this homework assignment: Create on the desktop a folder with your name. Copy from your account XYZ@xyz.com two files, ...
58 views

### Bash script to capture error message and change exit status

I'm working with the Perforce command line client. I ...
20 views

### Python Mandelbrot Set Fractal

I thought I would give this months community challenge a try. This is my first time using Python. It does take quite a while to run and it's not very colourful but it works. ...
16 views

### Code taking up random values [on hold]

Some of my variables takes up values that I have no idea where they come from. This is what I've written : ...
19 views

### Performing a fast Fourier transform on an audio file

I am using the accelerate framework in Swift to perform FFT on an audio file; however the magnitudes recorded aren't very accurate. How can I improve this code to get more accurate results? ...
126 views

I have implemented a thread safe inventory system. The Product is bound to a location in a warehouse. I have a Product class and ...
31 views

### Kruskal's algorithm

I'm working through Coffeescript implementing simple algorithms (started with Prim's as reviewed in this previous post) and wrote out Kruskal's algorithm as below, with a few helper functions. I'd ...
35 views

### Basic linked list implementation [on hold]

I have to implement my own linked list for a school project and here's what I have: ...
17 views

### Fastest infinite loop [on hold]

What is the fastest way to have in infinite loop in ruby that increments by 2. Here is what I currently have for a in 3.step(2) #Do things end
29 views

### c# GUI dice game code errors [on hold]

I m trying to make a GUI about dice game which allow two player roll 5 dices and made some progress but then i stocked about how to make some dices change and some of them not. For example: If player ...
40 views

### Database Connection Program

Earlier today I asked a question as a guest (whoops) regarding my Database program. I could not comment nor post again asking for further advice from the people that answered my question. I have ...
64 views

### MySQL-to-PostgreSQL migration script

I'm working on a Python script to migrate a MySQL database into a PostgreSQL database with a different Schema (different table structures, different datatypes and so on). I'm a sysadmin and ...
13 views

### User model with user roles in Codeigniter PHP/MySQL

I am building an app that currently allows the users to have 3 different roles: Consumer Merchant Admin I have three tables: user (Name, email, password etc with a status=0/1) user_role (The ...
28 views

### Prime generator for SPOJ

I have written code to solve the prime generator problem. I am given an input which contains in the first line the number of test cases, and for each test case, I am given a range and I have to print ...
15 views

### Scala - Console User Interface Framework

I've been learning Scala and I'd love to get your feedback in order to improve. As an exercise I made a simple framework for creating command-line user interfaces. Any and all comments are welcome, ...
47 views

...
85 views

### Database Connection Program With HR Functionality

I've started writing a fully functional Database program in C# that allows a user to access a HR system (with more systems planned in the future). I have come over to C# from Java around two weeks ...
232 views

### Reading a web page with Python [on hold]

When I am scraping from a web page I need a way to open and read it. Previously, I used two functions, one for requests and one for Selenium ...
68 views

### Accessing other properties within setter in WPF [on hold]

The following code works, but is it a good idea to call another method in a setter? ...
18 views

...
256 views

### Shrinking and expanding square

I'm a computer science student who's just starting out with algorithms and their implementation. I wrote this code for a dynamically morphing square. I was wondering if I could get a review on it. I ...
61 views

### MPMC lock-free queue

I'm pretty new to the world of lock-free programming and would love some feedback on this code. I have been testing the queue with multiple producers and consumers, and with no unexpected output ...
19 views

I know this is quite a generic question, I was hoping it could stay open so I can try to improve my styles. Basically, I have an application that connects to LDAP, performs searches, and produces a ...
80 views

### C++ implementation of merge sort

I am studying the merge sort algorithm and implemented it. In the mergeSort function, I am allocating two new vectors. Can I do it without allocating extra memory? ...
65 views

### Asking a user for the capital city of Peru, South America

Can this Python code be written in a more Pythonic way? ...
34 views

### Concatenating multiple strings from a JSON response

I would like to concatenate a series of strings populated from an XHR response. So, I've chosen to do it like this: ...
49 views

### An attempt at inheritance (Geometric Shapes)

I'm reading through the chapter on inheritance from C++ Primer 5th Edition. It asks Organize the following type into an inheritance hierarchy: (b) Geometric primitives (such as box, circle, ...
32 views

### HTTP client for company services

For quite a while now I've been writing a bit of Ruby code, but so far I still don't think it was good idiomatic Ruby. But there's been a new requirement and I tried my best writing it better, more ...
61 views

I'm following a YouTube video and am wondering if there are any other efficient ways of doing this. Is it possible to do it with an interface too? ...
73 views

### Sudoku challenge driver program

For my planned Sudoku with Handicap challenge over at codegolf.SE, I need a driver program. I've decided to write it in Python, for learning purposes. Since I've got no Python experience, I thought I ...
17 views

...
39 views

### Timing Python functions in two ways

When reviewing questions here on Code Review SE, I sometimes find my self wanting to test different functions in order to do a performance review. However since I'm inherently lazy, I wonder what is ...
Given two input directed graphs $G_1 = (V_1, A_1)$ and $G_2 = (V_2, A_2)$, the problem of isomorphism asks whether the two directed graphs are isomorphic, or in other words, whether the two input ...