problem (2,266)


algorithm - Two marbles and a 100 story building

algorithm - Two marbles and a 100 story building

One of those classic programming interview questions... You are given two marbles, and told that they will break when dropped from some certain height(and presumably suffer no damage if dropped from…


algorithm - Calculating a cutting list with the least amount of off cut waste

I am working on a project where I produce an aluminium extrusion cutting list. The aluminium extrusions come in lengths of 5m. I have a list of smaller lengths that need to be cut from the 5m lengths…


How do you prevent leading zeros from being stripped when importing an excel doc using c#

I'm able to connect to and read an excel file no problem. But when importing data such as zipcodes that have leading zeros, how do you prevent excel from guessing the datatype and in the process str…


performance - Is there some way to speed up recursion by remembering child nodes?

For example, Look at the code that calculates the n-th Fibonacci number: fib(int n){if(n==0 || n==1) return 1; return fib(n-1)+fib(n-2);}The problem with this code is that it w…


unix - What should we do to prepare for 2038?

I would like to think that some of the software I'm writing today will be used in 30 years. But I am also aware that a lot of it is based upon the UNIX tradition of exposing time as the number of seco…


asp.net - How do I prevent the closing of modal popup window(ModalPopupExtender) on postback?

I'm using Microsoft AjaxControlToolkit for modal popup window. And on a modal popup window, when a postback occurred, the window was closing. How do I prevent from the closing action of the modal pop…


What does it mean when a PostgreSQL process is “idle in transaction”?

What does it mean when a PostgreSQL process is "idle in transaction"? On a server that I'm looking at, the output of "ps ax | grep postgres" I see 9 PostgreSQL processes that look like the following:…


windows - How to make git ignore changes in case?

I'm not too sure what is going on here, but sometimes a particular file in my repository will change the case of it's name. e.g.,: before: File.h after: file.h I don't really care why this is happenin…



c# - Loader lock error

I am building on C++ dll, by writing code in C#. I get an error, saying LoaderLock was detected Message: Attempting managed execution inside OS Loader lock. Do not attempt to run managed code…


Algorithm/Data Structure Design Interview Questions

What are some simple algorithm or data structure related "white boarding" problems that you find effective during the candidate screening process? I have some simple ones that I use to validate proble…




how not the java with for example and error python