0
votes
1answer
35 views

REST and foreign key constraints

I have a rather complex database schema using foreign key constraints. This database schema will be accessed with REST services. Should REST or the database be responsible for referential integrity? ...
2
votes
1answer
94 views

How to name a function that makes sure an element exists and returns it?

function getOrInsertEmptyElemById(id){ var elem = $(id) || document.body.insert('<div id="'+id+'"></div>'); return elem; } I find myself using functions like the above quite ...
0
votes
0answers
44 views

Why was `Array.contains` renamed to `includes` if MooTools issue seems trivially resolvable? [on hold]

I find it a bit hard to follow the mailing list discussion, so I'm asking here. The way I understand it, the original problem with Array.contains was that MooTools was assigning it, and then ...
-2
votes
0answers
15 views

Use R to calculate binomial distribution and hypergeometric distribution [on hold]

Conduct a study to determine how well the binomial distribution approximates the hypergeometric distribution. Consider a bag with n balls, 25% of which are red. A sample of size (0.10)n is taken. Let ...
-3
votes
0answers
20 views

Help converting python::bitstream usage to PHP equivalent [on hold]

I need to read some data coming in from a client via a SOCKET using PHP. I found an example in python but I am not a python programmer. Here is the full python example code I am trying to covert. Note ...
0
votes
0answers
20 views

Can an http service queue up work via a timer?

I'll preface this by saying that I'm not particularly familiar with writing http services. To keep things simple, I'll use the metaphor of creating a collages from images selected by the user. The ...
0
votes
0answers
18 views

Prevent Timeout for large scripts without changing any System Settings

Current Option If I have a process that I know may take a while I have been chopping it up using ajax to do a part of the request then once the ajax is returned do the next part of the request. This ...
0
votes
0answers
36 views

web requesting - time competition - javascript? [on hold]

first of all, I would like you to excuse my english and description of the problem. I am not english native speaking, so I am trying my best.... Before you say, that is am abusing some server- I need ...
1
vote
1answer
21 views

Expectations on input / output of array dimensions and approaches to implement support for variable dimensions input arrays

Preamble As we are vectorising our colour API, we are changing the accepted input types for most of our functions. We would be keen on keeping backward compatibility with the existing code. Let's ...
0
votes
0answers
9 views

Code review for microcontroller 8051 [migrated]

I'm working with microcontroller 8051. I'm trying to simulate serial comunication on RS232 port. To do that, I need to take a single bit by bit from a number (ASCII value of a char) and put it on the ...
0
votes
4answers
48 views

Testing generic errors

I've got a program that validates it's input, and then errors. So far for each kind of error I created a new derived class. But this was getting pretty unwieldy (the input is complex so there are ...
0
votes
2answers
60 views

Control CPU Clock Speed with Software [on hold]

I am currently working on various performance analysis of algorithms. For this purpose I am for now using my MacbookPro. It completely fulfills my needs as the 4 cores (8 possible threads) also let me ...
0
votes
0answers
11 views

How to use an Address Gazatteer in an application that contains addresses

Say I had access to the post office address file (http://en.wikipedia.org/wiki/Postcode_Address_File) and wanted to cleanse about one million addresses. I am trying to think of an "algorithm" to do ...
-1
votes
0answers
61 views

What is difficult to write in SQL but easy in other programming languages? [on hold]

I know that SQL is a query language and not a programming language. Still SQL:2008 is Turing-complete 1 hence it should be possible to express everything you can write in other languages in SQL as ...
1
vote
2answers
36 views

How to handle inmutable data on Databases

I'm working on a quotation software. It basically creates quotations for customers based on certains ProductModel that contains n Plan that contains n PriceRange Edit: Here's a ER diagram of the ...
0
votes
0answers
8 views

Using .hta file to read registry values to create checklist

Internally in the company I work for we use ActiveX to do some browser automation to help save time on repetitive tasks. There are times where profiles are messed up or re-imaging happens and it ...
-2
votes
1answer
31 views

Service that compile & test your C code on different platforms [on hold]

I was wondering if there was some service that would compile & run automated tests on different platforms like multiple versions of Windows, Linux, Mac etc. and give you a report about any ...
0
votes
0answers
23 views

memory corrupted using std::vector in constructor [migrated]

Given an array of strings, I am writing a class to separated them into different groups according to their length, i.e. the ones of same length goes to the same group. The number of groups and the ...
13
votes
3answers
495 views

Why aren't “fat binaries” more widely used for cross-platform applications?

As far as I know, so-called "fat binaries"--executable files that contain machine code for multiple systems--are only really used on Apple PCs, and even there it seems like they only used them because ...
-1
votes
0answers
5 views

How to execute prepared statements inside stored procedures with user vars? [migrated]

I am trying to write a stored procedure to create a temporary table with variable columns created based on the linked data of 2 tables. I get the variable fields to be added to the temp table using a ...
4
votes
2answers
225 views

Should I use properties for the properties of properties?

Sometimes I use some indirect properties to set or get some other sub-properties, I give an example class Page { public string MainText { set { MainParagraph.Text = value; } get { return ...
-3
votes
0answers
38 views

Does Signal R make MSMQ, ActiveMQ, nBusService and MassTransit obsolete in web applications? [on hold]

on .NET platform we now have a new kid on the block. Signal R for those who do not know, it simply implments a push mechanism and makes it possible to call client side JS code from the server side ...
2
votes
3answers
123 views

3 tier architecture in .NET web applications

Nowadays most systems are designed as web apps. In the .NET world the famous three tier architecture is usually translated like this. Front End (Web Application) Middle Tier (custom DLLs using an ...
0
votes
1answer
50 views

Where to put utility classes in php mvc?

I'm working on my first MVC website, where can I put utility classes like Security and Date (my native date) classes, are they model too? App | |--- Model |--- Controller |--- View
0
votes
0answers
10 views

Dynamic Approach For LCA [on hold]

I reading a LCA Tutorial Where it defines P[1,N][1,logN] where P[i][j] is the 2j-th ancestor of i Why it is using logN and why 2j ancestor is used ? I did not understand it's intuition ?
0
votes
1answer
27 views

What is the best way to expose services to mobile devices? [on hold]

We are working on providing services to mobile devices(Android, iOS and Windows). These services mostly return data and nothing OS or any programming language specific. We are currently planning on ...
-3
votes
1answer
69 views

If I want write a programming language, what I have to know? [on hold]

I think about to take this course on coursera: https://www.coursera.org/course/compilers What knowledge I absolutely have to have in order to succeeded in this class? In particularly I'd like to ...
4
votes
1answer
51 views

Should I implement the consumer/producer pattern in my java video app, and if yes, how?

I built a small video frame analysis app with desktop Java 8. On each frame, I extract data (5 doubles now, but could expand to a 1920x1080x3 OpenCV Mat in the future). I would like to store this data ...
0
votes
0answers
37 views

Run App on server view on client [on hold]

I have been looking for a way for the last couple of months to run an application on my server while viewing on client. The main reasons for this is that the software needs to be updated regularly and ...
-4
votes
1answer
31 views

Create a main method to run the below code

I'm learning Java. I wonder how to run the below code? public class Test01{ public interface Printable{ public void print(); } public class PrintRectangle implements Printable{ public void ...
-5
votes
0answers
37 views

I want e-books related to programming [on hold]

I am new in programming world! . I want e-books related to JAVA , and C#.net . Best Regards, Abdulaziz.
-4
votes
0answers
28 views

How to test random numbers? [migrated]

Something is wrong with this PRNG, it uses a large (65536 bit) pool of bits from which randomness is extracted in sets of 256 bits, what seems to fail is the bit storage feature (ests,sts,lts,elts) ...
1
vote
0answers
26 views

Pipeline-like calculations with intermediate files: should I use a build system?

I have seen multiple examples of systems that are organized essentially like a pipeline. Each stage produces some intermediate files which are then consumed by the next stage. Also, these take a long ...
-4
votes
0answers
40 views

My trying to make the program decrement every 1 second. It keeps printing 99. What did I do wrong? [on hold]

# SimpleGUI program template # Import the module import simplegui # Define global variables (program state) countdown = 100 # Define "helper" functions def blast_off(): global countdown ...
1
vote
1answer
126 views

Hypothetical : What restrictions will I need to add to Java so that I can remove its GC? [on hold]

This is a hypothetical, yet very technically precise question I'm trying to ask all the compiler/static analysis programmers. I'm trying to understand the extent of prohibitive features I would need ...
-3
votes
0answers
18 views

Can someone help with a Swift / Xcode error code [on hold]

I am trying to submit an app to the app store (first time), had both iTunes connect and Xcode open at the same time trying to get profiles and certificates back and forth, and downloaded. At one point ...
0
votes
0answers
48 views

C++ ORM - but the other way

After days of searching and studying and making my brain wired I will try to put my thoughts and "questions" here. I think that there are millions of reasons for using ORM tools like ODB (together ...
2
votes
4answers
87 views

Single method with many parameters vs many methods that must be called in order

I have some raw data I need to do many things to (shift it, rotate it, scale it along certain axis, rotate it to a final position) and I am not sure what the best way to do this to maintain code ...
3
votes
1answer
179 views

raw, weak_ptr, unique_ptr, shared_ptr etc… how to choose them wisely

There is a lot of pointers in C++ but to be honest in 5 years or so in c++ programmation (specifically with the Qt Framework) I only use the old raw pointer : SomeKindOfObject *someKindOfObject = ...
-3
votes
0answers
38 views

Switching To Agile For Mainframe [on hold]

Our company is discussing whether to change from waterfall to agile for mainframe development. Has someone experience with this situation? What method are you currently using and how did process of ...
-3
votes
0answers
61 views

Bewildered: programming for the real world [on hold]

I'm currently working as a iOS developer. Before that I worked as a full stack web developer (JS, Ruby) while also maintaining the servers (linux). When I started out years ago I did a little game ...
-1
votes
0answers
24 views

Multi layer parallax live wallpaper [on hold]

I'm just starting android programming, and I'm trying to make a live wallpaper with multiple images and a parallax effect. I load the bitmaps at startup. This is my code for offset changed: ...
0
votes
2answers
86 views

Library design: better to leave potentially destructive feature in with a warning, or cut it out completely?

I recently created a red-black tree in C# to better understand how it works. With it, I implemented an in-order enumerator, however I quickly realized that enumerating a tree can have destructive ...
0
votes
1answer
81 views

dynamic programming with memoization

I’ve a problem with a programming exercise. I hope you can help me. In this exercise I need to find out what the maximum profit is of taking pictures from several items in a park. For taking pictures ...
-2
votes
0answers
33 views

Searching for a master's thesis topic #OpenCL #GPGPU [on hold]

I'm student of computer science, About 1 - 1,5 year ago I started learning about GPGPU, OpenCL, parallel programming etc. I like it, I'm interested in it, I want to do this. Recently I defended my ...
0
votes
1answer
97 views

Styleguide when coding in a static language

I am currently a junior engineer and keen on learning best practices and expanding my experience. My question concerns any static programming language such as Java, C#, C++ etc. When I am writing ...
-5
votes
0answers
43 views

Where can I learn about Dates/Timestamps? [on hold]

Where can I learn about dates and timestamps? My goal is to learn enough to be confident on making/using any date/timestamp. The general information seems to be very fragmented when going to ...
1
vote
2answers
84 views

MVC like design with interfaces: How to handle basic objects?

I have an (android) application and decided that the presentation layer will get data only through strict interfaces from the controller. I am at the point where some basic objects need to be passed ...
-1
votes
0answers
11 views

MySQL on delete cascade some levels [on hold]

How can I use on delete cascade or on update cascade for more than one level? consider: Table1 | |--Table2 | |--Table3 Table3 has a foreign key which references Table2 and Table2 ...
1
vote
2answers
93 views

Estimating run time of algorithm

For instance if i have an algorithm that is O(n2) and it will run for 10 seconds for a problem size of 1000. Now if i were to double the problem size to 2000 i want to know the approximate run time in ...

15 30 50 per page