-2
votes
0answers
38 views

Most common Non-Latin Bigrams and Trigrams for programming languages? [on hold]

I am looking for a list of the most common bigrams and trigrams in programming languages. For example, I develop using mostly Qt, ergo common Bigrams for me are: () ); (" ") (! Common Trigrams ...
0
votes
0answers
21 views

Multiple web apis under one domain

I am using ASP.NET MVC and I have a project where I need to build different integration rest APIs for different partners http://domain.com/api/integration/partner1 ...
0
votes
1answer
58 views

Uploading large files to web-server even if browser closed

I need to permit users to upload large files to my web-server even if the browser is closed. How can I implement this functionality. I have gone through the feasibility of google drive app but it ...
0
votes
3answers
150 views

A very basic question about whether I should check for null and throw NPE? [duplicate]

Consider the below method- public void operationOnList(List<String> list) { list.add(1); } It is obvious that if l is null this method will throw a NullPointerException. My question is ...
-1
votes
0answers
20 views

How would you write the following bit of Elixir code passing a function to the Enum.chunk_by? [on hold]

This is the bit of code I'd like to learn how to write using the anonymous function as the second parameter to the Enum.chunk_by. Enum.chunk_by([1, 2, 2, 3, 4, 4, 6, 7, 7], &(rem(&1, 2) == ...
5
votes
0answers
2k views

Why would someone use this type of cast in c? The reference of a float is cast to int pointer and then dereferenced [migrated]

I was reading about Carmack's fast inverse square root algorithm, and noticed this: float x; // ... // int i = *(int*)&x; Why would someone choose to use this weird type of casting instead of ...
-1
votes
0answers
82 views

Mechanism behind QR code scanning of whatsapp webapp [on hold]

I could not find any answers related to the working mechanism of qr code scanning used on whatsapp web-app. How does the authentication happen when the phone (any smartphone running whatsapp) scans ...
0
votes
1answer
74 views

What data structure to use to save the address of edges in depth first search?

I am currently trying to write my own Depth First Search. I have created a class called node. class node{ private: bool is_visited; <data structure to collect edges> ...
-2
votes
1answer
30 views

Hypothesis Testing on Statistical Data [on hold]

I am trying to figure out which is the best machine learning algorithm to use to solve this problem: Let's say I have a table, with each row such as this: {A, B, C, D, E} And I take in the values of ...
-2
votes
0answers
35 views

Solid KPIs for applying code review? [duplicate]

I am now trying to convince my teammates to do code review. But before that, I have to convince my team lead first. My team lead needs to know some solid KPIs to measure the benefits after doing code ...
-3
votes
0answers
21 views

Panel analysis in Mathematica? [on hold]

Can get I produce fixed effects/dummy variables using wolfram mathematica? Do I need to tinker with matrices to get results? I am trying to figure out which days my firm sees the highest amount of ...
1
vote
0answers
23 views

Building back end for iOS/Android app using Django and Heroku

Background: I'm currently building a music streaming app (many requests per second) for a friend and am second-guessing my approach to it. The plan is to have an iOS app and an Android app, though I ...
0
votes
2answers
163 views

How to implement backtracking to check if all fields have been traversed

I have been learning algorithms and trying to solve problems and now I have the following problem: In a 4x4 matrix, and it contains fields with height. There is a start field with given height also ...
1
vote
1answer
79 views

How to atomically create a new entity in multiple contexts without coupling?

Let's assume there are multiple contexts with the same logical entity but with different notions. Creating such an entity should have the side effect that in all other contexts the same logical entity ...
-3
votes
0answers
27 views

Tracing code flow, on very large projects [duplicate]

I am having a project in javascript, with many thousands lines of code, spread across hundreds of files. I am looking for a way to get familiar with the structure without having to debug and add ...
1
vote
1answer
92 views

Understanding recursive solution of some algorithm

Most of the time we need to understand someone else' code for example I am studying Graph Algorithms from Sedgewick's online resources, the particular code example is taken from cycle detection ...
8
votes
3answers
139 views

In REST parlance what is the difference between a resource and a representation?

My understanding of REST that is enables modelling service operations as representation of state and transition from one state to another making use of HTTP. I have always understood resources as ...
1
vote
1answer
73 views

When we need to serialize an exception

I have been developing in Java since 8 months, and I didn't face a case where I went to serialize an exception, I'm asking because I saw the serialVersionUID and how Eclipse advise to add it ...
2
votes
1answer
106 views

What functionality to expose in a database abstraction layer?

I'm trying to design a simple way of abstracting away data persistence behind an interface, but I'm having a hard time figuring out how much fine grained control should be exposed to higher layers. ...
0
votes
0answers
62 views

Best architecture for customising the character

I want to customize the game character before starting the level, for example, select what kind of weapon, armor, clothes, etc. There are several components and each component consist of several ...
1
vote
1answer
45 views

Generate a string generator (constant associative array)

There is a finite set of unique strings and a limited key space. One key corresponds to one string value and a function must exist to perform the resolution. There is no need to support other ...
2
votes
2answers
121 views

Placing preconditions in the right place

I am trying to figure out the best way to define the responsibility of checking preconditions. Let's consider the following case: we have an Event class representing a sports event and a Matchup ...
2
votes
1answer
116 views

What are the limitations of Java exception approach to errors?

Please ignore performance issues, I am interesting in data flow, safety, modelling, reasoning. I wonder what are the limitations of exception approach to error reporting implemented like in Java ...
1
vote
1answer
63 views

Is my understanding of dijkstra and plain Breadth-First Search correct?

I need to help to validate whether my understanding of when to use Dijkstra and when BFS are correct. My way of understanding BFS and Dijkstra, when to use what, am I correct? As I see it. Being ...
2
votes
1answer
129 views

Choice of variable names and types in graph algorithm

I am learning algorithms and data structures from this awesome resource Algorithms. Rather than doing dry reading I am trying to re-write all the code myself so that I can learn coding as well as ...
0
votes
1answer
53 views

What are the advantages of RxJS Observables over promises? [on hold]

It seems to me like Observables are basically wrappers for promises with some helper methods. It also requires a huge library to go along with it. Do the benefits of these helper methods outweigh the ...
0
votes
0answers
27 views

I am trying to make a function with that returns true/false if an element is in the vector but I am getting an error? [migrated]

I am trying to implement a function in C++ using STL which takes an object and a vector of objects and return true if the vector contains the object else false. Below is the implementation of the ...
2
votes
5answers
297 views

Why do I need to declare virtual functions as such?

Example: We have a base class Base and three subclasses which all implement their own version of doSomething(). In an intermediate function f(Base b), we want to call the relevant version of ...
0
votes
0answers
23 views

Reverse lookup of data based on user input

I have an array in the format: $array = array( 0 => array( 'name' => 'Item 1', 'level' => 1, 'points' => 10 ), 1 => array( 'name' => ...
0
votes
0answers
26 views

Resolve route before invoking middleware chain

Say I have a HTTP middleware chain that handles all incoming requests. Where should the incoming request be resolved into an appropriate route? I have thought about doing so before the middleware is ...
1
vote
0answers
39 views

Most efficient way of allocating participants to conference tracks

I am redesigning a system by which conference participants can choose which track they want to attend. Participants express their track preferences arranging them in order and submitting them at a ...
4
votes
3answers
109 views

Passing a private member collection to another class

Suppose I have a Map which is a private member variable of my class A. In the same class I create an instance of class B, call it objB, by passing the map to B's constructor. Obviously this is ...
4
votes
2answers
24 views

Test arrangement using the system under test

I have some integration tests around stored procs. Typically I do the test setup using Dapper. This is fine for simple cases, but in some cases to setup up the system correctly it would be far simpler ...
2
votes
1answer
69 views

What's the difference between an implementation detail and a technical concern

I just wanted to make sure that I understand and can properly articulate the difference between these two concepts. I've always thought of an implementation detail as being the internal workings of ...
0
votes
0answers
46 views

How to model space in a mudlike

I am trying to make a clone of the 3-D space-modeling system from swmud This is the criteria so far: (1) Objects in space will be either ships that can move or stationary things like non-moving ...
-4
votes
0answers
45 views

Does a donation have to be used only on the thing it was donated for? [closed]

I am currently in the process of developing an open-source computer application (http://sonrad-ai.tk) and it is taking up a lot of my free time, so I would like to get some sort of income from it, ...
0
votes
2answers
40 views

Best Communication strategy for monitoring dashboard

I have a requirement where I need to display certain stats on Admin Dashboard in my web application (Angular+Java). These stats (transnational data) are being generated on different servers (connected ...
2
votes
2answers
84 views

C++ vs Java: Pointing to Objects

In Java: private State current_state; As "State" is a superclass, I can then assign subclass objects to current_state, effectively making current_state point to a different object: current_state = ...
1
vote
2answers
56 views

Linux source reading without #ifdef [on hold]

I want to read Linux source code. Problem here is: source tree contains many files that are needed by different architectures. #ifdef conditionals distracts while reading code. I think, if somehow ...
0
votes
1answer
78 views

REST is not appropriate for business applications because of necessary to distribute business logic accross layers. REST alternative required!

I have Spring+Java Server Faces (Facelets) application for which I would like to create Single Page Application (SPA) version, e.g. using AngularJS (which is the best and most popular GUI framework). ...
-3
votes
0answers
14 views

popViewController doesn't work on UITableViewController [closed]

I have a UITableViewController embedded in a UINavigationController. Calling self.navigationController popViewControllerAnimated:YES in didSelectRowAtIndexPath method has no effect. My ...
-3
votes
0answers
18 views

JOptionPane check dialog to a String [closed]

So basically I want a input dialog to open up then, the user writes out an input. After that I check it to a String, if the String match I show them a message Dialog "Correct", if not show a message ...
0
votes
1answer
50 views

How to traverse “linked list” like structure with parallel nodes

I am working on a signal processing project that allows for parallel processing on data streams as well as inputs and outputs to and from multiple endpoints. The signal chain is broken down into ...
1
vote
1answer
44 views

Finding longest ambiguous words with a given set of letters

I have been playing hangman with my friend over an app for a while now, and we have a gentlemen's understanding between us that we are both "cheating" by using online software both to solve the given ...
-1
votes
0answers
27 views

Can I remove MIT license in my code? [duplicate]

I am using another software which in under MIT license. 1. If I do modification to the software code, can I remove the MIT license from the origin software? 2. If I sublicense this software to GPL, ...
3
votes
1answer
110 views

I feel like the more I improve the structure of my program I am writing a DSL [closed]

My project started out as spaghetti code. The more DRY and extensible I make my code, the more it looks like configuration files and code than runs them. Is that a good thing or does that mean I am ...
-5
votes
0answers
33 views

PYTHON SyntaxError: Non-ASCII character '\xc3' [closed]

I have the following code, but when trying to compile I get Traceback (most recent call last): File "/usr/lib/python2.7/runpy.py", line 163, in _run_module_as_main mod_name, _Error) File ...
0
votes
1answer
28 views

Serialized object data for template settings - best design? [on hold]

I am currently working on a CMS that uses HTML templates with PHP variables in it. A few of these stored variables: background_color font_size image_url Etc.. I am currently categorizing these ...
-2
votes
0answers
55 views

Shall I rewrite my project if it's not hard to maintain, but has some design/implementation mistakes? [closed]

I realized that my project doesn't use the default classes provided by the platform for commonality and connectivity between my program and the others. My classes are harder to connect to the ...
-2
votes
0answers
27 views

How do I find the TTF font name for Adobe Normalizer (i.e. Times New Roman) [closed]

I'm trying to use Adobe Normalizer to convert PostScript files to PDF/A. The problem I am having is that if a font isn't found it is a hard stop. I added the "--ignorestdttfonts=off" and that helps ...

15 30 50 per page