0
votes
0answers
10 views

Is it bad practice when an interface method implemented by a class does not use all its parameters?

Should an interface method implemented by a class always use all parameters? By interface I do not necessarily mean actual interfaces, these could be other (abstract) classes which are extended, too. ...
0
votes
0answers
4 views

Algorithm to generate all paths between two vertices of a graph in F#

Following a functional programming approach (no mutable data structures, recursion, etc) I have written a script in F# to generate all paths between two vertices of an undirected, unweighted graph. I ...
0
votes
2answers
33 views

What's the difference between writing to the memory address of a declared int and writing directly to an int*?

I'm writing a program in which I fscanf a file and write to the same memory address repeatedly. I tried the following: FILE *f = fopen(fname, "r"); int* num; while(fscanf(f, "%d,", num) != EOF) { ...
5
votes
4answers
3k views

How does Chrome V8 work? And why was JavaScript not JIT-Compiled in the first place?

I have been researching Interpreters/Compilers, then I stumbled across JIT-Compilation - specifically Google Chrome's V8 Javascript Engine. My questions are - How can it be faster than standard ...
4
votes
3answers
653 views

is while loop intrinsically a recursion?

I wondered whether a while loop is intrinsically a recursion? I think it is because a while loop can be seen as a function that calls itself at end. If it is not recursion, then what the difference?
0
votes
0answers
5 views

Microservices in the Large (specifically: foreign refs)

There are lots of good resources on μServices that focus on concepts like Single Purpose, REST, Implementation and Deployment, CI/CD, Encapsulation and Isolation, Separating UI from API, etc. However,...
0
votes
0answers
12 views

Thought driven development

How to proceed programming in new language and in a completely different paradigm, how to understand the underlying architecture? one thought process would be to completely avoid it and on the other ...
-2
votes
0answers
10 views

Finding and handling all the corner cases while writing a os dependent library

I need to know what is the best strategy while developing a public facing API that handles manipulating files. What error conditions I may need to handle? Reference: https://github.com/vivekimsit/...
1
vote
1answer
56 views

jersey post with a huge payload

I have a requirement to write a POST endpoint where the payload is huge(not normal). In the order 10s of Megabytes. And this endpoint will be accessed by a lot of clients (in the order of 1000s) ...
1
vote
1answer
22 views

Microservice architecture shared domain models

Lets assume that we have a Spring Boot application that uses microservices architecture. Each of the services has its own domain models, but each service must reference a User domain object. What ...
100
votes
5answers
16k views

Is there any reason to use the “var” keyword in ES6?

Babel's guide to ES6 says: let is the new var. Apparently the only difference is that var gets scoped to the current function, while let gets scoped to the current block. There are some good ...
3
votes
0answers
20 views

How do you model has-a (aggregation) relationships in functional programming languages

Just to be on the same terms: Aggregation is a has-a relationship, where the owned components can exist independently of the owning component.E.g. a pond and some ducks swimming in it. A duck leaving ...
4
votes
1answer
7k views

Why sending a file is so difficult using angular? [closed]

I have to send a file (very large file) to a server. I'm studying what options I have and how to do it. I'm using angular + express + nodejs. If I use a simple form, I could catch the file on the ...
0
votes
0answers
44 views

AngularJS modal windows chain suggestion

AngularJS 1.4.x. After time I've spend creatin' my confirmation modal alon' of bunch of another modals, I've faced an issue with spaghetti code in my controllers. Problem: imagine i have methods ....
0
votes
1answer
26 views

Optimal load distribution with maximum workload

I need to find an optimal distribution of some matching tasks on multiple jobs; each job is limited by a maximum workload and the grouped tasks should maximize the workload within the same job. ...
-1
votes
0answers
34 views

Why do programming language authors choose not to implement UFloat?

I realized I haven't seen this type in Objective C or Swift. But we have UInt. Is there some more Computer Science specific reason we do not have an Unsigned Float? Afaik it's not in c# too.
0
votes
1answer
25 views

How to handle modification on MIT Licenced project

i'm about to work fork an MIT licenced project, i'm planning to use it as a starter. I was wondering how i have to handle the licence. What I understand When I will mimifie my javascript ...
0
votes
0answers
40 views

Pass the parser to the sorter, or pass the sorter to the parser?

I have 2 objects that I'm not very certain what is the proper (or better) way I should use. I have a query builder object that constructs an SQL statement like $qb = new SelectQuery('users'); $qb-&...
-1
votes
1answer
68 views

What is a good OS for getting maximum performance out of a C++ program? [on hold]

I am looking to run a C++ program without any interference (context switching) from other processes. Is there a small operating system that will allow me to stop all other processes? Is there a bare ...
0
votes
2answers
54 views

Store and access my objects using an int id

I have created a class HidDevice to form objects which concatenates input from each HIDDevice separately until a special key (ENTER) is pressed. So each instance of HidDevice have fields like int ...
3
votes
1answer
124 views

Effect of demoting copy-on-write page to read-write on other processes

The Windows OS tries to conserve physical memory usage by allowing DLLs loaded in their base (desired) address in different processes to use the same physical pages with copy-on-write semantics; this ...
-1
votes
1answer
42 views

Is Angular 2 ready for production use or should I use AngularJS 1? [on hold]

I want to learn AngularJS but on the website I see a button with the text Try the new Angular 2. Is Angular 2 ready for production use or should I learn and use AngularJS 1?
0
votes
1answer
93 views

Is pure RESTful required for Angular JS / Backend running on same web server?

I am developing an application with Sprintboot + REST + Angular. While I am working on the REST API, I am trying to design as RESTful as possible. I'm encountering certain pages where the Angular UI ...
10
votes
3answers
13k views

Should I be using both AngularJS and ASP.NET MVC?

I started learning AngularJS and ASP.NET MVC, but am not sure why to use them both together in the same project? Aren't they both MVC frameworks? Should I be using them both in the same application? ...
1
vote
1answer
283 views

Pros and Cons of odd iframe 'architecture'

I'm in the process of experimenting with ways of breaking up a large (and growing project). Currently, we're working with a big Angular application with what will soon be a large number of components. ...
0
votes
0answers
34 views

HTML Encoding - XSS protection

My general rule for web development is that the server encodes HTML tags in any user-generated input when it is first submitted to prevent XSS. However recently someone suggested that instead of ...
4
votes
1answer
4k views

General way to convert a loop (while/for) to recursion or from a recursion to a loop?

This problem is mainly focusing on the algorithm, maybe something abstract and more academic. The example is offering a thought, I wanna a generic way, so example is only used as to make us more ...
1
vote
1answer
13 views

Consistency for disk write in a model object graph

You're writing an app where the model (as in MVC) is an object graph. Occasionally, you want to save this object graph to disk. What are some best practices to ensure that the write is consistent? (...
3
votes
1answer
40 views

Algorithm for seating Zoombinis on Captain Cajun's ferryboat?

I've been playing the rerelease of The Logical Journey of the Zoombinis recently, and trying to implement some computer algorithms that can solve the various puzzles. I'm stuck on how to approach the ...
2
votes
2answers
81 views

How to retrieve policy after Dynamic Programming?

I'm working on a simple resource allocation problem, that I'm solving using backward DP. The full code is at: http://codereview.stackexchange.com/questions/123641/allocating-a-resource It works fine, ...
-1
votes
0answers
10 views

Minimum value of a node in a binary search tree

I am making a program that returns the minimum value of a binary search tree recursively and I don't know how to implement it. I am stucked here, please help def bst_min(t): if t.is_leaf == True: ...
-2
votes
0answers
25 views

Difference Between `int static array[]` and `int array[]`?

I was to program a code for which i have to make a array to store more than million elements . But when i did it , it cannot store more than 120 thousand element so i read somewhere that if i instead ...
-2
votes
0answers
20 views

how to find each point of arc that i can draw the arc manualy in visual basic [on hold]

[![iwant acod that when enter the start point value and end point value and center point value in ther textboxes in the programe and hit button1 the programe will give me in msgbox coordinate of each ...
-1
votes
0answers
15 views

Name for “1:1” sourcefile - testfile convention

A classic convention for organizing test files is to maintain a 1:1 mapping between source files and test files. One common scheme is to simply append "-test" or "-spec" to the source filename and ...
6
votes
2answers
10k views

How to deal with database connections in a Python library module

I have created a library in Python that contains functions for accessing a database. This is a wrapper library around a third party application database, written due to the fact that the third party ...
2
votes
2answers
27 views

How can I track down a dependency that is causing an X509TrustManager error without having the source?

I am maintaining and Android app that now suffers from an unsafe X509 TrustManager implementation. Since the app doesn't make any HTTPS calls except through dependencies, one of the dependencies is ...
0
votes
0answers
16 views

Convention for writing the software details over the command line

What are the standard or more elegant ways of writing information about the software package? I have developed a package for one of machine learning methods in C++. I wish to provide information ...
0
votes
0answers
19 views

Using list of actions in language implementation

I'm implementing a small programming language as a hobbyist. My first idea was to compile the language to some kind of a intermediate language and then interpret it. However wouldn't it be a good ...
0
votes
0answers
7 views

How to properly test if a m3u8 video-stream is online and working properly?

I'm trying to define a method to properly define if an m3u8 video-stream is online and working correctly. What methods could I use? I want to make a cronjob that daily or hourly checks the validity of ...
0
votes
1answer
59 views

How do I manage a large state graph when building a scaleable finite state machine?

Lately I've been working on a project that involves parsing a toy domain-specific-language. While building it out, I realized that an efficient way to handle parsing tokens would be to represent the ...
0
votes
0answers
17 views

File folder contents versioning system

I'm sort of inspired from Amazon S3 and looking forward to advise on building my own versioning system on the server using plain nodejs/javascript with files provided by the client. Would also ...
-1
votes
1answer
30 views

Time complexity Computation

What will be the result of the time complexity of this piece of code i.e. int sum(int A[], int n) { int sum = 0, i; for(i = 0; i < n; i++) { sum = sum + A[i]; } ...
1
vote
1answer
34 views

Should commit messages be explicit by themselves, without requiring a diff?

I have noticed that I recently wrote the following commit message: Since HTML changed, getting the index would always result in zero, since the element is now enclosed in a parent block. For ...
-1
votes
3answers
52 views

When should we use MongoDB?

MongoDB is a NoSQL database which I've found quite easy to use. Recently I had to develop a simple application which needed to collect some data using HTTP requests and store some results after ...
4
votes
4answers
1k views

Is fixed-scope, fixed-time really impossible to deliver in agile? Or what else use?

I have been reading some similar questions here but they are not the same. The project we have inherited from our partner has fixed scope and a fixed deadline to deliver. We are now thinking about way ...
1
vote
0answers
39 views

Is there a cross-platform way to open a TCP connection, send a HTTP post request and keep the connection open?

I'm searching for a way to open a TCP connection, send a HTTP post request and keep the connection open. It would be great if I can achieve this without administrator/root rights, from a command-line ...
1
vote
3answers
329 views

How to approach hours forecasting

I need to forecast budgeted hours for 2 departments to help them schedule staff as currently the best they can do is just wing it. When we receive a job proposal I'll have the person submitting the ...
0
votes
1answer
66 views

Best way to encrypt passwords?

I've switched to PHP 7.0 very recently and I was wondering that if password_hash was better than making your own salt and using the crypt function. I have three examples of code and I don't know which ...
0
votes
0answers
35 views

Is it worth working on Google Closure now

I'm evaluating to whether to include this in my workflows. My workflow for JavaScript tools include and they offer me following. WebStorm (Excellent Code hinting, JSDocs comments, Refactoring etc.) ...
1
vote
2answers
225 views

Best way to manage Git branches in different environments

I had a basic question regarding using a git repository in different environments. I'm more of a Sys admin than a web developer, so the teams I've worked on before just worked right in the master, ...

15 30 50 per page